Major problem with software raid (mdadm) and disk failure
Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Major problem with software raid (mdadm) and disk failure
Ok, this is the case:
I've got two raid-5 arrays with software raid, both with three disks.
Setup:
md0 has hdb2, hdd1 and sda1
md1 has hdb5, hdd3 and sda3
Tonight, the system lost power due to a power spike. The result was a reboot where it attempted to fix the raid, but it didn't exactly work. I have now booted a live CD and using utilities there.
It seems the checksum value is slightly off for all disks. And the update time is the same for some disks, but not all.
When I try mdadm --assemble /dev/md1 (or md0) with various options like force, scan, auto, etc - I get error messages like only 1 drive found, not enough.. no disks found and no mention of md0/1 found in config file.
What should I do? Which partitions (two in each array) do I pick as "these two are the one I should rebuild with"? And how do I actually FORCE mdadm to start an array with those two set devices?
md1 should be startable from just hdb5 and sda3, as those two still match. Once it is up, let it rebuild hdd3.
md0 will be trickier, because none of the disks match. hdd1 is the worst (oldest) so that's the one you want to start without and rebuild later, once you have the array going with just hdb2 and sda1.
I don't know if mdadm will let you assemble the array with hdb2 and sda1, maybe with some force/run persuasion. Worst case would be to actually re-create the array from those two disks.
Have you tried explicitly giving the device names of the partitions you want to add?
I can't test it right now, but something like
Code:
mdadm --assemble /dev/md1 /dev/hdb5 /dev/sda3
Then add --force and --run as needed. ;o)
Tried the following:
# mdadm --assemble /dev/md1 /dev/hdb5 /dev/sda3
no devices found for /dev/md1
# mdadm --assemble --force /dev/md1 /dev/hdb5 /dev/sda3
no devices found for /dev/md1
# mdadm --assemble --run /dev/md1 /dev/hdb5 /dev/sda3
no devices found for /dev/md1
# mdadm --assemble --force --run /dev/md1 /dev/hdb5 /dev/sda3
no devices found for /dev/md1
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.