Skip to contentSkip to conversation

RAID1 root - troubles booting in degraded mode

DISCUSSION Massimiliano Masserelli 2 participants 3 messages Oct 29, 2002 – Oct 30, 2002 MD RAID

lore
Share & tools
lore
#0 lore raw

Hi folks!

I've taken a look at the ML archives, and found an old thread (06/2002) on this subject, but found no solution.

I've a working setup with a two disks RAID1 root, which boots flawlessly. Troubles arise when simulating hw failure. RAID setup is as follows:

raiddev                 /dev/md0
raid-level              1
nr-raid-disks           2
nr-spare-disks          0
chunk-size              4

device /dev/hda1
raid-disk 0

device /dev/hdc1
raid-disk 1

If I disconnect /dev/hda before booting, the kernel tries to initialize the array, can't access /dev/hda1 (no wonder), marks it as faulty, then refuses to initialize the array, dieing with a kernel panic, unable to mount root.

If I disconnect /dev/hdc before booting, the array gets started in degraded mode, and the startup goes on without a glitch.

If I disconnect /dev/hda and move /dev/hdc to its place (so it's now /dev/hda), the array gets started in degraded mode and the startup goes on.

Actually, this is already a workable solution (if the first disk dies, I just "promote" the second to hda and go looking for a replacement of the broken disk), but I think this is not _elegant_. 8)

Could anyone help me shedding some light on the subject?

Tnx in advance.

Signature · 4 lines
Massimiliano Masserelli
-------------------------------------------------------------------------------
Mayor: "Uh... try to have her home by eleven."
	--Buffy the Vampire Slayer: Enemies
#1 lore raw

Hi Massimiliano
Have you tryed to set partition id to 0xFD <raid autodetect>, and use a boot string as:
root=/dev/md1 ro devfs=mount vga=791
I have the same configuration, and I have a grub bootloader on each raid disk.

Emilio Gargiulo

Alle 00:07, mercoledì 30 ottobre 2002, Massimiliano Masserelli ha scritto:

Quoted 33 lines

Hi folks!

I've taken a look at the ML archives, and found an old thread (06/2002) on this subject, but found no solution.

I've a working setup with a two disks RAID1 root, which boots flawlessly. Troubles arise when simulating hw failure. RAID setup is as follows:

raiddev                 /dev/md0
raid-level              1
nr-raid-disks           2
nr-spare-disks          0
chunk-size              4

device /dev/hda1
raid-disk 0

device /dev/hdc1
raid-disk 1

If I disconnect /dev/hda before booting, the kernel tries to initialize the array, can't access /dev/hda1 (no wonder), marks it as faulty, then refuses to initialize the array, dieing with a kernel panic, unable to mount root.

If I disconnect /dev/hdc before booting, the array gets started in degraded mode, and the startup goes on without a glitch.

If I disconnect /dev/hda and move /dev/hdc to its place (so it's now /dev/hda), the array gets started in degraded mode and the startup goes on.

Quoted 7 lines

Actually, this is already a workable solution (if the first disk dies, I just "promote" the second to hda and go looking for a replacement of the broken disk), but I think this is not _elegant_. 8)

Could anyone help me shedding some light on the subject?

Tnx in advance.

-
To unsubscribe from this list: send the line "unsubscribe linux-raid" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

#2 lore raw
Quoted 2 lines · Emilio Gargiulo

Have you tryed to set partition id to 0xFD <raid autodetect>, and use a boot string as: root=/dev/md1 ro devfs=mount vga=791

Yes, I tried, but to no avail. Creating an initrd image with mdadm in the startup script solved the issue.

Bye.

Signature · 4 lines
Massimiliano Masserelli
-------------------------------------------------------------------------------
L'importante e` di non fare di tutta la merda un fascio.
                -- Altan