in over my head with triple-boot

Bart Whiteley bart.plug at whiteley.org
Sun Oct 29 22:41:09 MST 2006


On 10/29/06, Michael Torrie <torriem at chem.byu.edu> wrote:
>
> On Sun, 2006-10-29 at 21:35 -0700, Shane Hathaway wrote:
> > So LVM on the root partition is working for you?  I've heard that's
> > problematic.  It should be possible using initramfs, but have the
> > distros actually finished the work required?
> >
> > You might try installing without LVM.  Then you could use gparted from a
> > CD to reclaim the wasted space.
>
> One multi-boot tip I have with grub is to install each distro's grup
> config to the partition itself, rather than the MBR. Then have one
> distro in charge of the MBR.  Set up grub entries to chainload the other
> grubs on the partitions.  This is what I do to dual-boot solaris and
> fedora.  The reason I do this is so that respective kernel upgrades can
> add entries to their respective grub.conf files.  If you boot all
> distros from the same grub you'll have to always remember to change the
> one grub.conf file.


Yeah.  What he said.  I have _all_ of my distros install grub into the
boot sector of the root partition, rather than the MBR.  Then I have
another GRUB (stage{1,2} and menu.list) on another non-system partition
(such as /home) that is installed into the MBR.

For example, assume you have the following:
hda1: Windows
hda2: swap
hda3: extended
hda5: SUSE
hda6: Fedora
hda7: Ubuntu
hda8: /home

In such a situation, you'd probably want to install Windows first.  Then
install one of the linux distros, say SUSE.  Install with root partition at
hda5 and /home at hda8.  Install GRUB into the MBR just this one time
only.  Then, after you boot into the SUSE system the first time, do the
following:

- cp -a /boot /home/
- grub-install --root-directory=/home /dev/hda
- grub-install /dev/hda5

This installs the grub files from /home/boot/grub into the MBR, and the
files from /boot/grub into the boot sector of /dev/hda5.

Next, edit /home/boot/grub/menu.lst.  Change all of the entries to
chainloader directives.  Like this:

default 1
timeout 8
title Legacy OS
    chainloader (hd0,0)+1
title SUSE
    chainloader (hd0,4)+1
title Fedora
    chainloader (hd0,5)+1
title Ubuntu
    chainloader (hd0,6)+1


Now, whenever you install a Linux distro, make sure you
install grub into the boot sector of the root partition, rather than
the MBR.  If you forget to do this, or if the distro's installer doesn't
allow this (I think Ubuntu does not), no big deal.  It's easy to fix.
After booting into the distro that clobbered the MBR, repeat these
commands:

- grub-install --root-directory=/home /dev/hda
- grub-install /dev/<root_dev>



More information about the PLUG mailing list