bug-grub
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

I don't understand how grub gets its inner configuration.


From: lmckusic
Subject: I don't understand how grub gets its inner configuration.
Date: Sun, 5 May 2002 23:22:57 -0700
User-agent: Mutt/1.2.5i

Dear Grub Bug People,

I have a Red Hat 7.2 Linux system running Grub 0.90.

I think my problem is I don't understand all the places where grub gets 
configured with boot time disk information.  

My Red Hat 7.2 was installed and set up with the hard disk
as the primary master boot hard disk /hda

I want to plug a Windows 95 disk in as the primary master
boot hard disk /hda... 
then use a grub boot floppy to boot my Linux disk 
as the primary slave hard disk /hdb (second hard disk on the first ide cable)

So I approached grub thinking "If I just change all
occurances of /dev/hda to /dev/hdb and make another boot
floppy then I will be able to boot my existing Linux hard
disk." I expect to edit /etc/fstab when I have the prior
parts of the boot process working.

Well I have tried to make a grub boot floppy two ways.

So far, as long as my Linux hard disk is /dev/hda both boot
floppies work.

Both boot floppies fail when I insert a new disk as /dev/hda
and expect the boot process to find the Linux disk at
/dev/hdb

You can see my device.map below. 

My system is a really plain
FIC motherboard with 1 floppy, 1 or 2 hard disks and an
IDE-Cdrom on IDE cable 2. The bios is set for the
conventional boot order: floppy, disk1, cdrom

>From the documentation, I don't really understand which
disks should be named in the device.map. 

Is device.map a list of drives in the system or is it 
the list of which drives to visit for getting a boot sector? 

If I want grub to
boot ONLY from /dev/hdb should device.map say only that
drive?

Next, while running grub root and grub setup by hand I saw
an Error 16 Inconsistent file system message. I couldn't
tell if this problem was caused by grub.conf or device.map.

I commented out just about everything I could from grub.conf
and the Error 16 message continued.



Grub boot floppy 1 is made using the FAQ instructions titled: 
How to create a GRUB boot floppy with the menu interface?

I did a mount /mnt
mke2fs, copy stage1, copy stage2, copy e2fstage1_5, 
copy grub.conf, copy device.map and run 
grub root (fd0), 
grub setup (fd0) error messages quoted below
umount /mnt

Grub boot floppy 1 shows GRUB GRUB.... endlessly on screen
when Linux is on /hdb. Floppy 1 works when Linux is /hda.


Grub boot floppy 2 is made using grub-install /dev/fd0 with
the same grub.conf and device.map

Grub boot floppy 2 shows "GRUB and then
music-smiley-square-music-music-square-eta-boxframe-B (odd
characters) when Linux is on /hdb. Floppy 2 works when Linux
is on /hda


Use instructions from the FAQ
How to create a GRUB boot floppy with the menu interface?
do the mke2fs, mount it, copy files, run the example root and setup commands.
Seeing the request for e2fs_stage1_5 file, copy it too, get this result:

    GRUB  version 0.90  (640K lower / 3072K upper memory)
...

grub> find /boot/grub/stage1
 (fd0)

 grub> root (fd0)
  Filesystem type is ext2fs, using whole disk

  grub> setup (fd0)
  Checking if "/boot/grub/stage1" exists... yes
  Checking if "/boot/grub/stage2" exists... yes
  Checking if "/boot/grub/e2fs_stage1_5" exists... yes
  Running "embed /boot/grub/e2fs_stage1_5 (fd0)"... failed (this is not fatal)
  Running "embed /boot/grub/e2fs_stage1_5 (fd0)"... failed (this is not fatal)
  Running "install /boot/grub/stage1 d (fd0) /boot/grub/stage2 p /boot/grub/grub
.conf "... failed

Error 16: Inconsistent filesystem structure

--- device.map

(fd0)   /dev/fd0
(hd0)   /dev/hda
(hd1)   /dev/hdb

--- grub.conf

address@hidden root]# cat /boot/grub/grub.conf
# grub.conf generated by anaconda - edited by Lee for hdb booting
#
# Note that you do not have to rerun grub after making changes to this file
# NOTICE:  You have a /boot partition.  This means that
#          all kernel and initrd paths are relative to /boot/, eg.
#          root (hd0,0)
#          kernel /vmlinuz-version ro root=/dev/hda8
#          initrd /initrd-version.img
#boot=/dev/hda
#default=0
#timeout=10
#splashimage=(hd1,0)/grub/splash.xpm.gz
title Red Hat Linux (2.4.7-10)
        root (hd0,0)
        kernel /vmlinuz-2.4.7-10 ro root=/dev/hda8
        initrd /initrd-2.4.7-10.img

        title Alternate /hdb Image  (2.4.7-10)
        root (hd1,0)
        kernel /vmlinuz-2.4.7-10 ro root=/dev/hdb8
        initrd /initrd-2.4.7-10.img


Well, thanks for reading this inquiry.

My name is Lee McKusick and thanks again for this
and many other neat programs.
        



reply via email to

[Prev in Thread] Current Thread [Next in Thread]