The Indian Test match batsman scored 112 and Lumb scored 117 as the second division leaders totalled 357 for five, after being invited to bat first.
Notts had been reduced to 122 for three before Pujara and Lumb linked together in a fourth wicket stand of 185. Both then fell in the final session to Craig Miles, who claimed three for 88.
Pujara made only two against Glamorgan at Cardiff last weekend, hours after flying in from Mumbai. He cited ‘a spot of jet-lag’ for his low score but more than made amends with an innings of the highest quality.
Watchful throughout, the 29-year old picked his moments to pepper the various advertising hoardings all around the ground. The quality of his straight drives was more than matched by his clips through midwicket and square leg.
Gloucestershire appealed enthusiastically when the Indian was on 25, believing that Chris Liddle had been nicked behind, but umpire Jeff Evans was unmoved.
That apart, Pujara moved easily past his previous scores at Trent Bridge, efforts of 38 and 55 for his country in a 2014 Test match, and then 57 during his brief stint with Yorkshire a couple of years ago.
His 39th career century came in the 70th over when he caressed Kieran Noema-Barnett through the covers for his 13th four from 174 deliveries.
Lumb had enjoyed an eventful week in the build-up to his return to red ball form – this is only his second championship hundred since 2013. He’d sent down a couple of overs of gentle off-spin in the stalemate at Cardiff, his first bowl for five years. He then caddied for team-mate Stuart Broad on Wednesday, in the pro-am event before the PGA Championship at Wentworth.
Returning to his normal day job, the 37-year old survived a routine chance on 12, being spilled at point by Will Tavare, from the bowling of Miles.
Overcoming a slightly scratchy start, he blossomed in the sweltering conditions of the afternoon to punish a tiring attack and reach his hundred from 206 deliveries faced.
Miles had Pujara caught behind as soon as the second new ball was taken and then tempted Lumb to drive to point soon afterwards.
Earlier, openers Steven Mullaney and Jake Libby rattled along at the start of the day, putting 50 on the board inside nine overs before Gloucestershire fought back strongly.
Mullaney chipped Craig Miles to midwicket for 35 and Libby was pinned lbw by Matt Taylor for 32.
Samit Patel pulled Chris Liddle for six during his 15 but then nudged the same bowler to slip.
Pujara and Lumb joined forces around 20 minutes before lunch and remained together for the next 55 overs.
Riki Wessels and Chris Read took Notts through to the close and will start the second day needing only 43 to secure maximum batting points.