Recipe 12.9. Creating the GRUB Boot Menu

12.9.1 Problem

As fun as it is to discover root
devices and kernels from the GRUB command line, you would like to
preserve your boot parameters in a configuration file and have a nice
boot menu to use at startup. In this menu you will configure your
chosen defaults, and have a menu of all of your installed operating
systems to choose from.

The title can be anything at all, and you must have one—it
tells GRUB where each stanza starts, and it appears in the boot menu.
The other two lines are the same values we used on the GRUB command
line. It is not necessary to use the boot
command in menu.lst.

You can list as many operating systems as you want; each one requires
a stanza like this one. Make sure the kernel line points to the right
partition and kernel executable. It's common to have
several bootable kernels in the same root partition. And it is common
(even good) for all the boot configurations to use the same boot
partition.

Not all Linux distributions require a ramdisk,
which is loaded by the initrd image. If
/boot/initrd-* exists, you must use it.

12.9.3 Discussion

Remember that the root device, indicated by:

root (hd0,0)

is the location of the /boot directory, and
hd0,0 is GRUB's own numbering
system. On the kernel line: