Bug #7679 Crash recovery of BLOB fields leads to database corruption
Submitted: 5 Jan 2005 8:46 Modified: 5 Jan 2005 10:35
Reporter: Marko Mäkelä Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: InnoDB storage engine Severity:S1 (Critical)
Version:5.0.3-bk OS:Any (all)
Assigned to: Marko Mäkelä CPU Architecture:Any

[5 Jan 2005 8:46] Marko Mäkelä
Description:
The dummy index records written to the redo log do not indicate that BLOB fields need variable-length length fields. Thus, redoing an insert of a BLOB field longer than 127 bytes will lead to corruption of new-style InnoDB tables.

How to repeat:
Run ibtestblobold and force crash recovery at an appropriate time.

Suggested fix:
In mlog_open_and_write_index(), treat DATA_BLOB type fields analogously to fields with maximum length > 255.
[5 Jan 2005 10:35] Marko Mäkelä
Fixed in source repository.