A quick defeat, to go with the innings-and-261-run reverse at Lord's, seemed on the cards when Michael Vaughan declared the England innings on 447 for three at lunch, with a minimum of 60 overs left in the day.
Bangladesh had only managed 108, 159 and 104 in their three previous visits of the series, each time being bowled out inside 40 overs.
But, despite a late three-wicket burst in nine balls from seamer Matthew Hoggard which allowed England to claim an extra half hour to try to wrap up victory, the tourists clung on.
They had opened with a 50-run opening stand, while Javed Omar (71), Habibul Bashar (63) and Aftab Ahmed (67 not out) all scored half-centuries, the first for Bangladesh in the series, as England's bowlers lost their focus during the final session.
Only four Tests since the Second World War have ended in two days.
Scorecard:
Bangladesh 1st innings 104 (S. Harmison 5-38)
England 1st innings (Overnight: 269-3)
M. Trescothick c Ashraful b A. Ahmed 151
A. Strauss lbw b Mortaza 8
M. Vaughan c Mashud b Mortaza 44
I. Bell not out 162
G. Thorpe not out 70
Extras (b-1 lb-6 nb-3 w-2) 12
Total (for 3 wickets declared, 78 overs) 447
Fall of wickets: 1-18 2-105 3-260
Did not bat: A. Flintoff, G. Jones, G. Batty, M. Hoggard, S. Harmison, S. Jones
Bowling
Mortaza 22 - 4 - 95 - 2
Baisya 15 - 2 - 80 - 0 (nb-2)
Rafique 18 - 0 - 107 - 0
Hossain Munir 15 - 1 - 102 - 0 (nb-1 w-1)
A. Ahmed 8 - 0 - 56 - 1 (w-1)
Bangladesh 2nd innings
J. Omar c G. Jones b Harmison 71
N. Iqbal c G. Jones b Flintoff 15
R. Saleh c Strauss b Flintoff 7
M. Ashraful c Hoggard b Batty 12
H. Bashar lbw b Flintoff 63
K. Mashud lbw b Hoggard 25
A. Ahmed not out 67
M. Rafique b Hoggard 2
A. Hossain c Thorpe b Hoggard 0
T. Baisya not out 18
Extras (lb-6 nb-9 w-1) 16
Total (for 8 wickets, 69 overs) 296
Fall of wickets: 1-50 2-75 3-101 4-125 5-195 6-235 7-245 8-249
To bat: M. Mortaza
Bowling
Hoggard 14 - 3 - 62 - 3 (nb-4)
Harmison 15 - 1 - 77 - 1 (nb-3)
S. Jones 10 - 1 - 49 - 0
Flintoff 15 - 2 - 58 - 3 (w-1)
Batty 15 - 2 - 44 - 1