Skip to contentSkip to conversation

Booting from a raid1 device ?

DISCUSSION Don Jessup 8 participants 9 messages Oct 27, 2003 – Oct 28, 2003 MD RAID

lore
Share & tools
lore

Don Jessup

author
#0 lore raw

Is it possible to boot from a raid1 device with the md.o built as a
2.4.22 kernel module?

=====
Don Jessup
Asaca/Shibasoku Corp. of America
400 Corporate Circle, Unit G
Golden, CO 80401
303-278-1111 X232
[email protected]
http://www.asaca.com

#2 lore raw
In reply to Don Jessup
Quoted 3 lines · Don Jessup

Is it possible to boot from a raid1 device with the md.o built as a
2.4.22 kernel module?

Yes, but it's tricky. You'd have to load md.o and raid1.o in your initrd (or other early boot time initialization) and then use some, e.g., statically-linked mdadm tool on that initrd to start the array. You cannot, however, use md's RAID autodetect to autostart arrays that have their component partitions marked as RAID autodetect (0xfd), if md is a module.

--
Paul

Quoted 12 lines

=====
Don Jessup
Asaca/Shibasoku Corp. of America
400 Corporate Circle, Unit G
Golden, CO 80401
303-278-1111 X232
[email protected]
http://www.asaca.com
-
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

#3 lore raw
Quoted 10 lines · Paul Clements
Quoted 2 lines · Don Jessup

Is it possible to boot from a raid1 device with the md.o built as a
2.4.22 kernel module?

Yes, but it's tricky. You'd have to load md.o and raid1.o in your initrd (or other early boot time initialization) and then use some, e.g., statically-linked mdadm tool on that initrd to start the array. You cannot, however, use md's RAID autodetect to autostart arrays that have their component partitions marked as RAID autodetect (0xfd), if md is a module.

BTW, assuming I have md.o not as module but statically in the kernel, which bootloader would support RAID1? I heard LlLO does this job but does also grub
- which I prefer - support Linux SW-RAID1?

What about RAID5? Is there any bootloader that supports it?

Best Regards,
Hermann

Signature · 3 lines
[email protected]
GPG key ID: 299893C7 (on keyservers)
FP: 0124 2584 8809 EF2A DBF9  4902 64B4 D16B 2998 93C7
#4 lore raw
Quoted 9 lines · Hermann Himmelbauer
Quoted 1 line · Paul Clements

Don Jessup wrote:

BTW, assuming I have md.o not as module but statically in the kernel, which bootloader would support RAID1? I heard LlLO does this job but does also grub - which I prefer - support Linux SW-RAID1?

What about RAID5? Is there any bootloader that supports it?

It has been a while since I read it, but doesn't the Boot+Root+Raid+Lilo howto [google] go into those setups ? It helped me a lot at the time...

A related question: There are a lot of old and deprecated Raid howto's floating around the net, even about the antique version 0.4.
Is there no mechanism that gets these (very confusing for a newbie!) old versions removed or upgraded ? And is this Boot+Root+Raid+Lilo howto I mentioned deprecated, or not ? Shouldn't it be integrated into the 'official' Raid howto ? (Or at least, there could be links to each other in the howtos)

Greetings,
Maarten

Quoted 2 lines

Best Regards,
Hermann

Signature · 1 line
Yes of course I'm sure it's the red cable. I guarante[^%!/+)F#0c|'NO CARRIER
#5 lore raw

Boot+Root+Raid+Lilo howto

Quoted 23 lines · Hermann Himmelbauer
Quoted 9 lines · Paul Clements
Quoted 1 line

Don Jessup wrote:

BTW, assuming I have md.o not as module but statically in the kernel, which bootloader would support RAID1? I heard LlLO does this job but does also grub - which I prefer - support Linux SW-RAID1?

What about RAID5? Is there any bootloader that supports it?

It has been a while since I read it, but doesn't the Boot+Root+Raid+Lilo howto [google] go into those setups ? It helped me a lot at the time...

A related question: There are a lot of old and deprecated Raid howto's floating around the net, even about the antique version 0.4.
Is there no mechanism that gets these (very confusing for a
newbie!) old versions removed or upgraded ? And is this Boot+Root+Raid+Lilo howto I mentioned deprecated, or not ? Shouldn't it be integrated into the 'official' Raid howto ? (Or at least, there could be links to each other in the howtos)

Quoted 3 lines

Greetings,
Maarten

The obsolete Root-Raid-HOWTO, covers all you need to know about booting raid using initrd -- that used to be the only way you could do it.

I'm the author of Boot+Root+Raid+Lilo and the answer to your first question is yes... and ... no.

The howto is up to date with respect to how booting occurs and what is necessary to get disks of various geometries to work when they are not the same or when the motherboard bios does not automatically switch to the next numeric device when the first hard drive will not boot. It does not cover using the newer LILO which does not require specifying the geometries, but then it will not deal with those exceptions either. Everything in Boot+Root+Raid+Lilo works for the new LILO just fine, it just doesn't mention the easier setup which in my opinion only covers a small number of the boot requirements. i.e. Current HOWTO is far more comprehensive and I still recommend multiple lilo.conf files -- one for each boot drive. That way it's always correct, even for the corner conditions.

And.... no, I've not updated it in some time but there really isn't anything new.

Michael Robinton
[email protected]

#6 lore raw
In reply to Hermann Himmelbauer
Quoted 3 lines · Hermann Himmelbauer

BTW, assuming I have md.o not as module but statically in the kernel, which bootloader would support RAID1? I heard LlLO does this job but does also grub
- which I prefer - support Linux SW-RAID1?

grub doesn't yet afaik.

Quoted 1 line

What about RAID5? Is there any bootloader that supports it?

No.

Sincerely,
Lars Marowsky-Brée <[email protected]>

Signature · 8 lines
High Availability & Clustering	      \ ever tried. ever failed. no matter.
SUSE Labs			      | try again. fail again. fail better.
Research & Development, SUSE LINUX AG \ 	-- Samuel Beckett

-
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
#7 lore raw
Quoted 7 lines
Quoted 3 lines · Hermann Himmelbauer

BTW, assuming I have md.o not as module but statically in the kernel, which bootloader would support RAID1? I heard LlLO does this job but does also grub
- which I prefer - support Linux SW-RAID1?

Quoted 6 lines

grub doesn't yet afaik.

Quoted 1 line

What about RAID5? Is there any bootloader that supports it?

No.

The appropriate solution is to put an 8-16 meg partition as the first partition on the first two drives (all the drives) in the system. Set those up as raid one and mount them on /boot. Use these as the boot boot partitions in a mostly raid 5 system. Likewise, segment swap partitions into pairs on the raid5 disk set and create raid 1 arrays for swap

Michael

#8 lore raw
In reply to Lars Marowsky-Bree
Quoted 8 lines · Lars Marowsky-Bree
Quoted 3 lines · Hermann Himmelbauer

BTW, assuming I have md.o not as module but statically in the kernel, which bootloader would support RAID1? I heard LlLO does this job but does also grub
- which I prefer - support Linux SW-RAID1?

grub doesn't yet afaik.

What does this exactly mean. I always use GRUB for Raid1 setup with boot partition an md device, and I'm beginning to think I'm using it the wrong way!

What I do is I 'setup' the partitios from a floppy:

title Install GRUB into (hd0,0) the first disk
root (hd0,0)
setup (hd0)

title Install GRUB into (hd1,0) the second disk
root (hd1,0)
setup (hd1)

Both partitions (hd0,0) and (hd1,0) are part of /dev/md/0

At that point I'm able to start from both devices... BTW I've never been able to do that w/o passing from a floppy. If I do that from the CD I use to install everithing seems OK but it doesn't boot.

Signature · 3 lines
Sandro Dentella  *:-)
e-mail: [email protected] 
http://www.tksql.org                    TkSQL Home page - My GPL work