Dhaka: Bangladesh were 107/5 at stump after Pakistan declared on 557/8 on day 2 of the second and final Test against Bangladesh in Mirpur on Thursday.
Bangladesh lost five wickets in the final session. The host trial by 450-run and they need 251 to avoid follow-on.
Azhar Ali hit a maiden double-century as Pakistan reached 557 for eight by tea.
Azhar scored a career-best 226 and Asad Shafiq made 107 during a fifth-wicket stand of 207 before Pakistan lost four wickets in the space of 27 runs just before tea.
Off-spinner Shuvagata Hom removed Azhar and Shafiq in successive overs, both batsmen falling to catches on the long-off fence by Mohammad Mahmudullah.
Left-arm spinner Taijul Islam dismissed Wahab Riaz and also sent back Yasir Shah off the last ball before tea to leave Sarfraz Ahmed unbeaten on 21.
Pakistan lost skipper Misbah-ul Haq in the day's second over, bowled by Shakib Al Hasan for nine, before a run had been added to the overnight score of 323 for 3.
Younis Khan had made 148 on the first day after Bangladesh captain Mushfiqur Rahim won the toss and elected to field at the Sher-e-Bangla stadium.
Brief scores
Pakistan - 557/8 dec (Azhar 226, Younis 148, Shafiq 107, Taijul 3-179)
Bangladesh - 107/5 (Yasir 2-15)
Status - Bangladesh trial by 450 runs