Bug 67580 - Updating /boot makes grub unbootable
Summary: Updating /boot makes grub unbootable
Keywords:
Status: CLOSED WORKSFORME
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: grub
Version: 7.3
Hardware: i386
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Jeremy Katz
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2002-06-27 18:21 UTC by hjl
Modified: 2008-05-01 15:38 UTC (History)
0 users

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2002-12-29 06:31:59 UTC
Embargoed:


Attachments (Terms of Use)

Description hjl 2002-06-27 18:21:25 UTC
On 2 machines, one notebook and one desktop, installing
my own rpm:

# rpm -ql BOOT
/boot/initrd-2.4.18-5.2BOOT
/boot/vmlinuz-2.4.18-5.2BOOT
/var/lib/BOOT
/var/lib/BOOT/addinitrd
/var/lib/BOOT/kickstart.sample

with "rpm -U BOOT-...." makes grub unbootable. On notebook,
I got

GRUB Geom Error

On desktop, I got

GRUB

Running "grub-install" again fixes the problem. Is that normal?

Comment 1 hjl 2002-06-27 18:58:57 UTC
# rpm -q --scripts BOOT
postinstall scriptlet (through /bin/sh):
cat <<EOF
If you use LILO as the boot loader, please add

image=/boot/vmlinuz-2.4.18-5.2BOOT
        label=BOOT
        initrd=/boot/initrd-2.4.18-5.2BOOT

to /etc/lilo.conf and run

$ lilo
$ lilo -R BOOT

Then reboot the machine. It will start the installation process
automatically.

If you use grub as your boot loader, please add

title Red Hat Linux (Install/Upgrade)
        root (hd0,0)
        kernel /vmlinuz-2.4.18-5.2BOOT
        initrd /initrd-2.4.18-5.2BOOT

to /boot/grub/grub.conf. Then reboot the machine and choose the
"Red Hat Linux (Install/Upgrade)" option at the grub menu to start
the installation process.
EOF


Comment 2 Jeremy Katz 2002-08-11 20:22:06 UTC
I don't have any problems with this here; we do it all the time as part of our
normal testing framework.  What filesystem type are you using for /boot?

Comment 3 hjl 2002-08-17 19:50:03 UTC
I am using ext3 on /boot. It happened twice again.
One is I removed an image and add a new image
in /boot. I edited grub.conf to reflect that.
After reboot, grub would reboot the machine
over and over again. I had to boot CD into
rescue mode and run grub-install to fix it.
My grub.conf:

default=0
timeout=10
splashimage=(hd0,0)/grub/splash.xpm.gz
title Red Hat Linux (2.4.18-5.3)
        root (hd0,0)
        kernel /vmlinuz-2.4.18-5.3 ro root=/dev/sda2 hdd=ide-scsi
        initrd /initrd-2.4.18-5.3.img
title Red Hat Linux (Install/Upgrade)
        root (hd0,0)
        kernel /vmlinuz-2.4.18-5.3BOOT ks=hd:sda2/var/lib/BOOT/upgrade.ks
        initrd /initrd-2.4.18-5.3BOOT

I changed the second entry by hand.

Another time is I upgraded the kernel with rpm.
I was dropped into a grub prompt after reboot.
I had to run grub-install also. I have

default=0
timeout=10
splashimage=(hd0,1)/grub/splash.xpm.gz
title Red Hat Linux (2.4.18-5.4)
        root (hd0,1)
        kernel /vmlinuz-2.4.18-5.4 ro root=/dev/hda3 hdc=ide-scsi
        initrd /initrd-2.4.18-5.4.img
title Red Hat Linux (2.4.18-5.2 ACPI)
        root (hd0,1)
        kernel /vmlinuz-2.4.18-5.2acpi ro root=/dev/hda3 hdc=ide-scsi
        initrd /initrd-2.4.18-5.2acpi.img
title Red Hat Linux (2.4.18-5.2 Custom)
        root (hd0,1)
        kernel /vmlinuz-2.4.18-5.2custom ro root=/dev/hda3 hdc=ide-scsi
        initrd /initrd-2.4.18-5.2custom.img
title Red Hat Linux (2.4.18-5.2 PCMCIA)
        root (hd0,1)
        kernel /vmlinuz-2.4.18-5.2pcmcia ro root=/dev/hda3 hdc=ide-scsi
        initrd /initrd-2.4.18-5.2pcmcia.img
title Red Hat Linux (Install/Upgrade)
        root (hd0,1)
        kernel /vmlinuz-2.4.18-5.3BOOT ks=hd:hda3/var/lib/BOOT/upgrade.ks
        initrd /initrd-2.4.18-5.3BOOT
title Windows XP
        rootnoverify (hd0,0)
        chainloader +1



Comment 4 Jeremy Katz 2002-12-29 06:31:59 UTC
This works fine for me here in testing with current packages.  FWIW, I recommend
using grubby to do the addition to the config files as it can handle updating
both lilo and grub config files correctly (see /sbin/new-kernel-pkg for how it's
done on kernel package installs)


Note You need to log in before you can comment on or make changes to this bug.