Adding Chromium OS to Grub2’s menu…

Once you have Chromium OS installed you may want to customize the Grub2 menu to have a more friendly name than what the default is.

First, open a terminal and cd to the /etc/grub.d/ directory. Next, remove the executable flag from ’10_linux’, ’20_memtest86+’ and ’30_os-prober’:

$ sudo chmod -x 10_linux
$ sudo chmod -x 20_memtest86+
$ sudo chmod -x 30_os-prober

Then edit the ’40_custom’ file:

$ sudo gedit 40_custom

You can copy the entries that you want to keep from ‘/boot/grub/grub.cfg’ into the ’40_custom’ file so that you don’t have to manually recreate them. Mine looks like this:

#!/bin/sh
exec tail -n +3 $0
# This file provides an easy way to add custom menu entries.  Simply type the
# menu entries you want to add after this comment.  Be careful not to change
# the 'exec tail' line above.

menuentry "Chromium OS" --class gnu-linux --class gnu --class os {
insmod part_gpt
insmod ext2
set root='(hd0,gpt3)'
search --no-floppy --fs-uuid --set=root 00000000-0000-0000-0000-000000000000
linux   /boot/vmlinuz root=/dev/sda3 rw noresume noswap i915.modeset=1 loglevel=1 quiet
}
menuentry 'Ubuntu, with Linux 3.0.0-12-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
set gfxpayload=$linux_gfx_mode
insmod gzio
insmod part_gpt
insmod ext2
set root='(hd0,gpt14)'
search --no-floppy --fs-uuid --set=root 2c4d68b7-726e-4358-b2d0-acd77b6e3267
linux    /boot/vmlinuz-3.0.0-12-generic root=UUID=2c4d68b7-726e-4358-b2d0-acd77b6e3267 ro   quiet splash vt.handoff=7
initrd    /boot/initrd.img-3.0.0-12-generic
}
menuentry 'Ubuntu, with Linux 3.0.0-12-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod gzio
insmod part_gpt
insmod ext2
set root='(hd0,gpt14)'
search --no-floppy --fs-uuid --set=root 2c4d68b7-726e-4358-b2d0-acd77b6e3267
echo    'Loading Linux 3.0.0-12-generic ...'
linux    /boot/vmlinuz-3.0.0-12-generic root=UUID=2c4d68b7-726e-4358-b2d0-acd77b6e3267 ro recovery nomodeset
echo    'Loading initial ramdisk ...'
initrd    /boot/initrd.img-3.0.0-12-generic
}
menuentry "Memory test (memtest86+)" {
insmod part_gpt
insmod ext2
set root='(hd0,gpt14)'
search --no-floppy --fs-uuid --set=root 2c4d68b7-726e-4358-b2d0-acd77b6e3267
linux16    /boot/memtest86+.bin
}
menuentry "Memory test (memtest86+, serial console 115200)" {
insmod part_gpt
insmod ext2
set root='(hd0,gpt14)'
search --no-floppy --fs-uuid --set=root 2c4d68b7-726e-4358-b2d0-acd77b6e3267
linux16    /boot/memtest86+.bin console=ttyS0,115200n8
}

Now you need to update grub:

$ sudo update-grub2

Now cross your fingers and reboot! Congratulations! You have successfully added Chromium OS to your Grub2 menu! If you want to customize your menu even further, I recommend you read the following:

http://ubuntuforums.org/showthread.php?t=1195275

You may also want to check out http://chromeos.hexxeh.net/wiki/doku.php?id=multiboot for references to Chromium OS specific linux kernel commands needed on the kernel line within the Grub2 menu.

Comments are closed.