Booting GRUB

If there is no configuration file (or the configuration file does not specify a kernel to load), when GRUB loads it will display a prompt that looks like this:

grub>

GRUB expects a certain sequence of commands to boot a Linux kernel. They are as follows:

  1. root device

  2. kernel filename [options]

  3. initrd filename – optional, only present if an initial ramdisk is required

  4. boot

For example, the following sequence would boot a stock Red Hat 8.0 system with /boot on /dev/hda1 and / on /dev/hda2:

grub> root (hd0,0)
grub> kernel /vmlinuz-2.4.18-14 ro root=/dev/hda2
grub> initrd /initrd-2.4.18-14.img
grub> boot

Get LPI Linux Certification in a Nutshell, 3rd Edition now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.