Node:FAQ, Next:Obtaining and Building GRUB, Previous:Invoking mbchk, Up:Top
Technically speaking, GNU GRUB has many features that are not seen in
the original GRUB. For example, GNU GRUB can be installed on UNIX-like
operating system (such as GNU/Hurd) via the grub shell
/sbin/grub
(or /usr/sbin/grub
on older systems), it
supports Logical Block Address (LBA) mode that solves the 1024 cylinders
problem, and <TAB> completes a file name when it's unique. Of
course, many bug fixes are done as well, so it is recommended to use GNU
GRUB.
Furthermore, some operating systems (i.e. DOS) cannot access any large
disk, so the problem is not solved by any kind of boot loader. GNU/Hurd
and GNU/Linux can surely boot from such a large disk.
$ mke2fs /dev/fd0
/mnt
.
/mnt/boot/grub
. Only stage1
,
stage2
and menu.lst
are necessary. You may not copy
stage1.5s.
/usr/sbin/grub
for
/sbin/grub
if you are using an older system):
$ /sbin/grub --batch <<EOT root (fd0) setup (fd0) quit EOT
0x63
to the GNU Hurd incorrectly. So use
0x83
if the partition contains ext2fs filesystem, and use
0xA5
if the partition contains ffs filesystem, whether the
partition owner is the Hurd or not. We will use 0x63
for the
GNU Hurd filesystem that has not been implemented yet.
ld -v
This will show two versions, but only the latter is important. If the version is identical with what you have installed, the installation was not bad.
Well, please try:
gcc -Wl,-v 2>&1 | grep "GNU ld"
If this is not identical with the result above, you should specify the
directory where you have installed binutils for the script configure,
like this:
./configure --with-binutils=/usr/local/bin
If you follow the instructions above but GRUB still crashes, probably
there is a serious bug in GRUB. See Reporting bugs.
For now, we know the following doesn't provide working LBA mode:
In the case where you have such a SCSI controller unfortunately, you cannot use the LBA mode, though GRUB still works fine in the CHS mode (so the well-known 1024 cylinders problem comes again to you).
Caution: Actually it has not been verified yet if this bug is
due to the SCSI BIOS or GRUB itself, frankly speaking. Because the
developers haven't seen it by their own eyes. This is why it is
desirable that you investigate the cause seriously if you have the
skill.
mem=
option to your Linux kernel, like this:
grub> kernel /vmlinuz mem=128M
You may pass other options in the same way. See See GNU/Linux, for
more details.
Because GRUB is a boot loader and it normally runs under no operating
system, it doesn't know where a partition is mounted under your
operating systems. So, if you have the partition /boot
and you
install GRUB images into the directory /boot/grub
, GRUB
recognizes that the images lies under the directory /grub
but not
/boot/grub
. That's fine, since there is no guarantee that all of
your operating systems mount the same partition as /boot
.
There are several solutions for this situation.
/boot/boot/grub
instead of
/boot/grub
. This may sound ugly but should work fine.
cd /boot && ln
-s . boot
. This works only if the filesystem of the boot partition
supports symbolic links and GRUB supports the feature as well.
install
, to specify the paths of
GRUB images explicitly. Here is an example:
grub> root (hd0,1) grub> install /grub/stage1 d (hd0) /grub/stage2 p /grub/menu.lst
For example, if you want to install the boot loader for Windows, just
run FDISK /MBR
on Windows. If you want to install LILO1, run
/sbin/lilo
on GNU/Linux.