10.68. GRUB-0.97

The GRUB package contains the GRand Unified Bootloader.

10.68.1. Installation of GRUB

GRUB has an issue that can cause it to segfault when you try to configure a drive to utilize GRUB on x86_64 machines. The following patch fixes this problem:

patch -Np1 -i ../grub-0.97-use_mmap-1.patch

GRUB has an issue where it sometimes doesn't detect the disk geometry correctly when used with Linux 2.6, resulting in the error message Error 24: Attempt to access block outside partition. The following patch contains a fix for this issue as well as various fixes for raid controllers and support for the new Intel Mac:

patch -Np1 -i ../grub-0.97-fixes-1.patch

Prepare GRUB for compilation:

CC="gcc ${BUILD32}" ./configure --prefix=/usr

Compile the package:


To test the results, issue: make check.

Install the package:

make install
mkdir -pv /boot/grub
cp -v /usr/lib/grub/*/stage{1,2} /boot/grub

The directory in /usr/lib/grub (its name depends on your arch) contains a number of *stage1_5 files, different ones for different file systems. Review the files available and copy the appropriate ones to the /boot/grub directory. Most users will copy the e2fs_stage1_5 and/or reiserfs_stage1_5 files.

10.68.2. Contents of GRUB

Installed programs: grub, grub-install, grub-md5-crypt, grub-set-default, grub-terminfo, and mbchk

Short Descriptions


The Grand Unified Bootloader's command shell


Installs GRUB on the given device


Encrypts a password in MD5 format


Sets the default boot entry for GRUB


Generates a terminfo command from a terminfo name; it can be employed if an unknown terminal is being used


Checks the format of a multi-boot kernel