Initramfs-tools forcefully stars md arrays. How to disable it?
- To: firstname.lastname@example.org
- Subject: Initramfs-tools forcefully stars md arrays. How to disable it?
- From: Balint Laczay <email@example.com>
- Date: Sun, 5 Aug 2012 22:01:49 -0700
- Message-id: <CAMRNUvU37x45yj_Lhm3=k-My0rOY8j-JLf7zTZ=dHi-K3u7vYQ@mail.gmail.com>
initramfs-tools (0.98.8, the one in squeeze) uses the command below to
start up the array for the root filesystem (from line 91 of
$MDADM --assemble --scan --run --auto=yes $dev
This specifies --run, which makes mdadm start the array even if it can
only do so in degraded mode. This means, if I knock a SATA cable
loose, my machine will still boot, but dirty the array. Once I
notice, and reconnect the cable, I now have to run risky mdadm
commands to add the drive back, and then I have to rebuild the whole
What I'd actually like, is if my system failed to boot if any drive is
missing from the array. Then I'd have the opportunity to check the
cables, and if needed, boot a live CD for troubleshooting. I'd like
to make my own determination when do I give up on a harddrive, and
bring the array up in degraded mode. I understand, that probably for
most people, this is not what they want. They want high availability,
that's why they use raid. Maybe I'm using raid in the wrong
My question is how can you control this behavior? I see no way of
configuring initramfs-tools not to add the --run option. Would it
make sense to have such an option somewhere in the configuration?
Also, could we take this as far as giving a prompt if the array did
not start in normal mode, to let the admin force the start in degraded
mode right there, without any need for a live CD or other maintenance?
I don't know how easy is it to do anything interactive from
local-top, and how portable that would be.
(BTW, first time post here, sorry if I hit the wrong list. Feel free
to redirect me.)