Bangladesh tail-enders Naeem Islam and Shafiul Islam scored maiden half-centuries to frustrate England as the hosts were eventually dismissed for 419 runs in their first inning of the second test on Sunday.
Bangladesh resumed the second day on 330-8 and batted for more than 24 overs in the morning session to add 89 runs, giving the hosts their highest ever test total against England.
The tally is Bangladesh's third highest against any side, behind the 488 scored against Zimbabwe at Chittagong in 2005 and 427 against Australia at Fatullah in 2006.
Off-spinner Graeme Swann claimed the last wicket shortly before the lunch break when he had Rubel Hossain lbw for 17 to finish with 4-114 in the innings.
Naeem added 26 runs to his overnight total to remain unbeaten on 59 after facing 172 balls and hitting eight fours.
Shafiul led Bangladesh's charge in the morning, racing to his first test fifty off 47 balls with a boundary through the cover off the bowling of James Tredwell.
Paceman Tim Bresnan gave England their much-needed breakthrough when he dismissed Shafiul for 53 with wicketkeeper Matt Prior taking the catch to end a ninth-wicket stand of 74.
At the lunch interval, England were 4-0 after five overs with skipper Alastair Cook scoring all the runs. Fellow opener Jonathan Trott was yet to get off the mark.
Bangladesh used three of their four spin bowlers in the short spell before lunch, giving England a taste of what to expect on a slow and turning track as they chase a challenging total.
England lead the two-match series 1-0 after completing a 181-run win in Chittagong on Tuesday.