Pakistan, the hosts, scored 281 for four at the Dubai International Cricket Stadium Friday, with Azhar Ali, the top-order batsman, top-scoring with 100 - his maiden Test century - and the experienced Younis Khan making 55.
With Misbah-ul-Haq, the captain, batting on 40, Marsh, the former Australia opening batsman, said: "We need to get them out quickly on Friday. We are still in the game, but need to bat well the second time because bowling last would be an advantage."
Sri Lanka were bowled out for 239 in their first innings on day one.
Pakistan started slowly after resuming the day at 42 without loss, and benefited from two dropped catches off successive deliveries from Suranga Lakmal, who bowled well in the morning session.
Both openers, though, failed to take advantage of the lapses, with Taufeeq Umar edging Dhammika Prasad, the fast bowler, to Kaushal Silva for the wicketkeeper's first catch in Tests before Mohammad Hafeez was adjudged leg-before in Prasad's next over.
Thereafter it was Pakistan's day, with Azhar and Younis putting on 117 runs for the third wicket.