When installing ubuntu 9.10 karmic koala will grub2 work together with grub legacy

user1 bqz69 at telia.com
Sun Nov 1 22:49:21 GMT 2009


On Friday 30 October 2009 06:08:58 pm Goh Lip wrote:
> bqz69 wrote:
> > I have just installed ubuntu 9.10 on a pc, and grub2 worked perfect, and
> > made a grub2 login menu with my two other OS (wxp and 8.04), so I can
> > choose which of the three OS to login to at boot time

It did not work when I installed 9.10 on my other pc, a laptop. grub2 did not 
find any other OS, probably because they are all on encrypted partitions except 
the /boot partitions which are all on their own unencrypted partitions of 100 
mb

I fixed it, and here is an example for ubuntu 9.04 with /boot on sda7 and / on 
sda8:

I took the menu content lines from the /boot/grub/menu.lst of the 9.04:

title		Ubuntu 9.04, kernel 2.6.28-11-generic sda7 enc 959
uuid		da9ce616-b91d-4428-8987-28eac900f328
kernel		/vmlinuz-2.6.28-11-generic root=/dev/mapper/sda8_crypt ro quiet splash 
initrd		/initrd.img-2.6.28-11-generic
quiet

and changd them into:

menuentry "ubuntu 9.04 sda7/8" {
set root=(hd0,7)     
search --no-floppy --fs-uuid --set da9ce616-b91d-4428-8987-28eac900f328
linux /vmlinuz-2.6.28-11-generic root=/dev/mapper/sda8_crypt ro quiet splash
initrd		/initrd.img-2.6.28-11-generic
}

and then copied it into /etc/grub.d/40_custom and then ran "sudo update-grub" 
(which transfers it into /boot/grub/grub.cfg) this file must not be edited by 
hand.

Then I went to the /etc/default/grub file, and changed 2 lines:

from:
GRUB_HIDDEN_TIMEOUT=0
GRUB_HIDDEN_TIMEOUT_QUIET=true

to:
#GRUB_HIDDEN_TIMEOUT=0
GRUB_HIDDEN_TIMEOUT_QUIET=false

Then I ran "sudo update-grub" again, and then ubuntu 9.04 appeared in the 
grub2 bootloader menu, and could be started as normal.

I am not sure if the second line above "set root=(hd0,7)" is necessary, 
because I first inserted it as "set root=(hd0,1)" and it still worked??




More information about the ubuntu-users mailing list