Bug#534470: Using mdadm 2.6.7.2 to assemble a raid array created with mdadm 1.9.0 will corrupt it making mdadm 1.9.0 to crash when trying to reassemble

Neil Brown neilb at suse.de
Fri Jun 26 01:55:32 UTC 2009


On Wednesday June 24, francois-xavier.russotto at cea.fr wrote:
> Package: mdadm
> Version: 2.6.7.2
> Severity: critical
> 
> After booting a Debian 5.0.1 - Lenny install cdrom in rescue mode
> (debian-501-ia64-netinst.iso) on an Itanium 2 server with Debian 3.1
> - Sarge (ia64) installed on a software raid 5 root partition,
> opening a console in the root partition mounted from the raid array
> (auto-assembled) corrupts the raid array, leading to a kernel panic
> at server reboot, and preventing from manual reassembly using mdadm
> 1.9.0 (Sarge). 
> 
> The raid 5 array containing the root partition is made of 3
> partitions on 3 scsi disks (sda2, sdb2, sdc2) which ran fluently for
> years. Here is the output at server reboot: 
> 
> 	md: invalid superblock checksum on sdb2
....
> 
> Apart from fixing this bug, I would be grateful that you suggest me
> a safe way to make the server bootable again. I was thinking about
> booting on a Sarge install cdrom and try to re-create the raid array
> with option "--assume-clean" or, if that fails, re-create the array
> and restore content from a tar backup. 

This problem is due to the fact that the superblock checksumming
routine was changed since 2.6.8.
It was changed because it used code that was different on different
architectures, and was basically unmaintainable.
New kernels can accept most old checksums, but old kernels cannot
necessarily accept the new ones, and mdadm does not know enough about
kernel internals to always create the correct old one.

So it isn't really fixable.

If you boot with the Sarge install cdrom and reacreate the array with
--assume-clean as you suggest it should work fine.
Check the "--examine" values for chunksize and layout, and the order
of the drives, and make sure you preserve all of those.

NeilBrown





More information about the pkg-mdadm-devel mailing list