[plug] Booting with root RAID1 with a missing disk?

Andrew Furey andrew.furey at gmail.com
Sun Sep 10 16:39:37 WST 2006


Hi all,

My home gateway is not too healthy... I'm trying to set it up with
software RAID (which I've used before, although not in this
complicated a scenario with this machine).

The simple version is:

I have /, which is a 20Gb RAID1 setup of /dev/md0, containing
/dev/hda2 and /dev/hdc2. This all works (I have a simple initrd to
load the modules and run raidstart). I've also found the
raid-extra-boot=mbr-only option for LILO, to write the MBR to both
disks, so I can boot from either. This also works.

/dev/hda looks like it's failing (which is what prompted this in the
first place - looks like it's going back, again), so I'm trying to
configure it all to run degraded so I can take it out and do without
it for a few days. So I run

raidsetfaulty /dev/md0 /dev/hda2
and
raidhotremove /dev/md0 /dev/hda2

to kick it out of the array. This also works - the system is now
happily running off /dev/hdc2 solely, and it also still works on a
subsequent reboot.

Now the difficult bit - I unplug /dev/hda (with the power off, of
course) and start up again... and it won't boot :(

Here's the offending section:

md: could not lock hda2, zero-size? Marking faulty.
md: could not import hda2!
md: autostart hda2 failed!

and then it does the usual "can't find root" kernel panic.

I even tried sticking another old disk in with a 1-cylinder hda2
partition, in case the mere presence would be sufficient, but no:

md: invalid raid superblock magic on hda2
md: hda2 has invalid sb, not importing!
md: could not import hda2!
[etc]

Obviously if I could make another disk with a suitable RAID
superblock, there wouldn't be a problem... but that kinda defeats the
purpose :(

Anyone have any ideas?

Thanks,
Andrew

-- 
Linux supports the notion of a command line or a shell for the same
reason that only children read books with only pictures in them.
Language, be it English or something else, is the only tool flexible
enough to accomplish a sufficiently broad range of tasks.
                          -- Bill Garrett



More information about the plug mailing list