Jeremy Katz wrote:
On Sun, 2008-11-30 at 14:49 +0100, Hans de Goede wrote:
Jeremy Katz wrote:
On Wed, 2008-11-26 at 12:06 +0100, Hans de Goede wrote:
This patch removes a special case when /boot (or / without a separate /boot) is
on mdraid. For some reason we only allow installing grub to the mdX device then
instead of allowing both the mbr of the 1st disk and the device holding /boot.
I've searched through the anaconda history and this special handling of mdraid
/boot has been there since before Feb. 2002, it was inherited from before booty
was introduced and it does not seem to make sense. Either we cannot have /boot
on mdraid at all (in all cases except for raid1) or we can have /boot on dmraid
(in case of raid1) and then it does not matter if the bootstrap of grub starts
on the mbr or on the first sector of a partition.
The reason we install to the mdX device is so that if your disk dies,
the bootloader install is mirrored[1] to both disks. So while it is
technically possible to install to the mbr of the first disk, doing so
loses the redundancy of the RAID install.
Well, that is pretty useless, this could be usefull when the first disk (as
seen by the BIOS) dies, except that if 99% of the cases that happens the BIOS
will still see the disk and thus still try to boot from it and fail.
Some BIOSes actually fail over gracefully from this to the second disk
-- shocking that a BIOS would do something useful, but it occasionally
happens :-). But even in the cases of not, pulling the disk and being
able to boot is something that customers have actually counted on.
Software raid1 really only protects against data loss and keeps the system
running when a disk dies. It does not guarantee the system will still (re)boot
if a disk dies.
Moreover, grub (booty) does not actually install to the mdX device, it will
only install to the first partition of the raid set. Atleast that is how I read
the booty code. And this is no surprise as grub does not know anything about
mdraid.
grub doesn't know anything about it, but the code should be there to
install to both sides of the array.
You are right studying the code further this does indeed happen. And installing
to the first sector of the raid set partitions should be fine, assuming that
the disk has a dos like mbr which just bootstraps to the bootsector of the
active partition, but what if the disk does not have a valid mbr?
The RHEL48 bug I'm trying to fix is about not allowing installation to the MBR,
which is a valid bug I think, as we should allow that anyways. But one could
argue the old behavior is the best default, except that we are not sure in any
way then we have a valid mbr and thus a booting system.
Regards,
Hans
_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list