GRUB2

The main changes of GRUB2 from GRUB are as follows:

  1. GRUB2 directly shows a login prompt and no menu is displayed.

  2. If you want to see the menu during boot, hold down SHIFT key or press ESC

  3. The configuration file is /boot/grub/grub.cfg. This main configuration file contains different types of scripts we cannot edit this file directly. grub.cfg is generated from the contents of the /etc/default/grub and /etc/grub.d . You should modify or add to those files to configure GRUB 2

  4. There is no file called /boot/grub/menu.lst

  5. Users can create custom files to place their own menu entries via 40_custom in /etc/grub.d folder.

  6. Users can change the menu display settings through a file called grub in /etc/default folder.

  7. The numbering of partitioning has changed. The first partition is now 1 instead of 0. The first device is still identified with hd0

There are 3 stages to the GRUB2 process:

  1. boot.img is stored in the master boot record (MBR) or in the Volume Boot Records (VBR). At installation time it is configured to load the first sector of core.img:

  2. Also known as stage 1.5.core.img is by default written to the sectors between the MBR and the first partition, when these sectors are free and available. Once executed, core.img will load its configuration file and any other modules and file systems needed, at installation time, it is generated from diskboot.img and configured to load stage 2 by its file path

  3. Also known as stage 2. Files belonging to the stage 2 are all being held in the /boot/grub

Once GRUB2 stage 2 has loaded, it presents a kernel selection menu for the user to select which operating system to boot. GRUB2 can be configured to automatically load a specified kernel after a user-defined timeout

Once boot options have been selected, GRUB2 loads the selected kernel into memory and passes control to the kernel. Alternatively, GRUB2 can pass control of the boot process to another boot loader, using chain loading.

results matching ""

    No results matching ""