Azhar Ali struck his maiden Test double hundred and Asad Shafiq registered his sixth century as Pakistan took firm control of the second and final Test against Bangladesh.
After declaring their first-innings on a commanding 557 for eight, the visitors consolidated their position by blowing away the top half of the Bangladesh batting order to reduce them to 107 for five at the end of second day's play.
Shakib Al Hasan (14) was unbeaten at the crease for the hosts, who trail Pakistan by 450 runs with five wickets in hand and still need 251 runs to avoid follow-on.
Pakistan's 50-over captain Azhar, unbeaten on 127 overnight, brought up his double hundred with a six over long-on off left-arm spinner Shakib and went on to make 226.
Azhar, Shafiq press on
The right-hander added 207 for the fifth wicket with Shafiq (107) after Pakistan lost captain Misbah-ul-Haq (nine) early in the first session.
Azhar holed out in the deep trying to hit a six against off-spinner Shuvagata Hom, who also dismissed Shafiq after the batsman had completed his hundred.
Pakistan lost four wickets for 27 runs trying to increase the tempo, with left-arm spinner Taijul Islam (3-179) taking two wickets in an over prompting Misbah to declare at tea.
The declaration ended the misery for Bangladesh's bowlers but trouble started for their batsmen.
Left-arm seamer Junaid Khan dismissed last test's double centurion Tamim Iqbal (four) in the first over and sent back Mominul Haque (13) to give Pakistan a strong start with the new ball.
Leg-spinner Yasir Shah bowled Imrul Kayes (32) before dismissing Bangladesh captain Mushfiqur Rahim (12) with the last ball of the day to compound the hosts' crisis.
Paceman Wahab Riaz accounted for Mahmudullah (28).
Bangladesh blanked Pakistan 3-0 in the ODI series and also won the lone Twenty20 match before drawing the first test at Khulna, despite conceding a huge first innings deficit.
Pakistan 557-8d (Azhar 226, Islam 3-179)
Bangladesh 107-5 (Kayes 32, Shah 2-15)