Ubuntu Karmic Alpha 5 Editing GRUB2

I used to know how to edit /boot/grub/menu.lst to change the order of Operating Systems (e.g. Windows XP, Ubuntu Jaunty, Ubuntu Karmic, and Kubuntu Jaunty), set the default, and set the delay. But with alpha 5 of Ubuntu Karmic that has all changed with the introduction of GRUB2. Here’s what I did instead.

Your goal is to change /boot/grub/grub.cfg but you shouldn’t do that directly. You should change some config files and then run a special grub update command.

Open one of the config files for other OSs (as root):
sudo gedit /etc/grub.d/30_otheros
[update]
sudo gedit /etc/grub.d/30_os-prober

I commented out redundant entries e.g. different kernel versions, and then saved it.

Then edit the main grub config file:
sudo gedit /etc/default/grub

I changed the relevant line to:
GRUB_DEFAULT = 4
so that the 5th item (0,1,2 …) would boot by default.

Finally, run the grub update command to regenerate /boot/grub/grub.cfg:
sudo update-grub

You can check the result in /boot/grub/grub.cfg to see everything went well.

Not a lot trickier than under plain GRUB and apparently GRUB2 has a lot of possible benefits depending on your circumstances (http://www.gnu.org/software/grub/grub-2.en.html).

BTW GRUB2 has attracted some controversy and there are some interesting points in the following article and its comments (http://aronzak.wordpress.com/2008/09/30/stay-away-from-grub2/).