Grub error 15 - found the problem, need some help anyway!

I had OpenSUSE 10.3 and decided to install OpenSUSE 11.1

I used the DVD, and went for an update. It seemed to work most of the way, but upon rebooting I was presented with a missing file error.

I examined the menu.lst file, and found that it contained the line: kernel /boot/vmlinuz-2.6.22.18-0.2-default

It looks to be the exact same menu.lst I had before (i.e. no change was made to the menu.lst after the update). Trying to reinstall grub with the rescue mode fails.

My /boot directory contains the following (I’m using WinXP to examine my ext3 partitions, which frankly impresses me no end - shame it’s not standard and I had to install extra programs to do it, but still, things have come a long way in the past five years):

24/01/2009  16:43    <DIR>          grub
24/01/2009  16:43    <DIR>          boot
24/01/2009  18:25           442,880 message
24/01/2009  18:25         5,714,697 initrd
05/12/2008  03:09           126,323 symsets-2.6.27.7-9-pae.tar.gz
05/12/2008  02:48         1,092,495 System.map-2.6.27.7-9-pae
05/12/2008  03:01            95,522 config-2.6.27.7-9-pae
24/01/2009  16:54         2,531,376 vmlinuz
05/12/2008  03:09           402,978 symtypes-2.6.27.7-9-pae.gz
05/12/2008  03:03           119,746 symvers-2.6.27.7-9-pae.gz
05/12/2008  03:01         3,260,966 vmlinux-2.6.27.7-9-pae.gz
05/12/2008  02:48         2,531,376 vmlinuz-2.6.27.7-9-pae
24/01/2009  18:25         5,714,697 initrd-2.6.27.7-9-pae
19/04/2008  19:07               512 backup_mbr

Looks to me like the new kernel wasn’t quite installed? But the old one is gone. I’m at a loss for what to do with this, so now I’ve come here for help. I hope I’ve done enough legwork that someone with more experience and knowledge than me can give advice.

I had more than once some head-scratching about grub.
So here are my 10 Cents.

First off I found this one very helpful:
Gentoo Grub Error Collection” Gentoo Linux Documentation
(or for German:
Gentoo Grub Fehlersammlung” Gentoo Linux Dokumentation)

Now to your concrete problem.
For me it looks more that the new kernel is there, but menu.lst didn’t get updated. menu.lst talks about
kernel /boot/vmlinuz-2.6.22.18-0.2-default
but your listing shows:
vmlinuz-2.6.27.7-9-pae
That’s newer.
You probably just have to fix your menu.lst. (See the second part below)

Second trick:
My experience shows, that the rescue mode doesn’t work that well for grub problems. I usually tried to fix them using grub itself or using a live system.
Here is how:
[Sorry, this is a try of a translation of my private how-to from German to English]

  • For the next time you should print /etc/fstab, /boot/grub/menu.lst and your Boot order in BIOS before you get a failure.
    (I too learned this the hard way…)

  • Grub simply counts all disks (IDE and SCSI). This is true
    also for the order of the IDE drives. The first HDD in BIOS
    gets number 0; (1 == primary slave).

  • grub also counts partitions from 0
    Partitions 0 -? are primary, 4 -… are extended.

  • On the graphical boot screen press ESC

    • Confirm the he horrified query that you will leave the graphical mode
    • Voila: the grub menu
  • Subminiature instructions

    • Look for path to stage1 on all disks
      grub> find / boot/grub/stage1
    • Enter the desired partition as the boot partition for grub
      (The one where you found the stage1)
      e.g.
      grub> root (hd0, 0)
    • Write the Configuration to disk
      (Here MBR on first disk is used)
      grub> setup (hd0)
    • Leave grub
      grub> quit
    • Reboot
  • If boot fails, because the kernel and / or initrd aren’t found
    ( “Error … File not found”, unfortunately without specifying which file)
    then you have a problem: ‘find’ finds only files with full
    Pathname given, but not any file with wild cards.

    • Trick: Knoppix (or another live system)
    • After booting mount the relevant partitions
    • search for the file
    • edit menu.lst accordingly

HTH

Martin

Right, editing menu.lst

Here is how it stands at the moment:


# Modified by YaST2. Last modification on Sat Dec 13 21:41:15 GMT 2008
default 2
timeout 8
gfxmenu (hd1,5)/boot/message

###Don't change this comment - YaST2 identifier: Original name: linux###
title openSUSE 10.3 - 2.6.22.18-0.2
    root (hd1,5)
    kernel /boot/vmlinuz-2.6.22.18-0.2-default root=/dev/disk/by-id/scsi-SATA_SAMSUNG_SP0842NS0DWJ1DL928714-part6 vga=0x31a resume=/dev/sdb5 splash=silent showopts
    initrd /boot/initrd-2.6.22.18-0.2-default

###Don't change this comment - YaST2 identifier: Original name: failsafe###
title Failsafe -- openSUSE 10.3 - 2.6.22.18-0.2
    root (hd1,5)
    kernel /boot/vmlinuz-2.6.22.18-0.2-default root=/dev/disk/by-id/scsi-SATA_SAMSUNG_SP0842NS0DWJ1DL928714-part6 vga=normal showopts ide=nodma apm=off acpi=off noresume nosmp noapic maxcpus=0 edd=off 3
    initrd /boot/initrd-2.6.22.18-0.2-default

###Don't change this comment - YaST2 identifier: Original name: windows 1###
title windows 1
    rootnoverify (hd1,5)
    chainloader (hd0,0)+1

###Don't change this comment - YaST2 identifier: Original name: windows 2###
title windows 2
    rootnoverify (hd1,5)
    chainloader (hd1,0)+1

###Don't change this comment - YaST2 identifier: Original name: windows 3###
title windows 3
    rootnoverify (hd1,5)
    chainloader (hd1,1)+1

###Don't change this comment - YaST2 identifier: Original name: floppy###
title Floppy
    rootnoverify (hd1,5)
    chainloader (fd0)+1

Do I take it you suggest changing

vmlinuz-2.6.22.18-0.2-default

to read

vmlinuz-2.6.27.7-9-pae

and

initrd-2.6.22.18-0.2-default

to read

initrd-2.6.27.7-9-pae ?

I don’t know why there are three windows options; this is how it came out of the autogenerator and since it worked I didn’t fiddle with it.

yes that change is what you want to do
as for the three windows entries, you have three ntfs for vfat partitions which makes it look like three windows os’s just delete the one that are unnecessary

See my reply in the other forum you posted same question. Saves me typing more.

For anyone reading, the advice in the other forum was to use the DVD Rescue tools to install a new bootloader - sadly I have tried that already and it failed miserably.

Editing the menu.lst file as discussed above has enabled me to boot to SUSE. I noted during boot that the superblock on a couple of disks did not match the backup ,and a check was forced. No further complaints that I saw, though. It’s definitely not a well SUSE, as there seems to be a real dearth of picture icons and the network connections have disappeared. I might just salvage any data I need to keep and eradicate the whole lot and start again.

IMHO it was risky to upgrade from 10.3 to 11.1, skipping one distro. It’s not a big job now to clean up your /home partition & you can format the root partition and re use that for 11.1

Well, now I know.

Okey dokey, that sounds like the best course of action. Potentially silly question time now;

I’ve got three partitions for the Linux. One is about 1.5 GB, and I believe it to be the swap space. The other two are around 15GB each, both EXT3 filesystem. One contains a shedload of directories such as boot, dev, etc, home; the other contains only two directories, one named lost+found and the other named my username. The one to format and start again with is the one with boot, dev and so forth on.

If any of that flashes a warning sign, please stop me! In other news, I was poking at it just now and it made a really, really alarming noise that might be from WinXPs attempt to read the SWAP space but nonetheless was not a noise I like to hear! If I stop posting completely, it’s because a HDD has exploded and shredded the motherboard.

I’ve got three partitions for the Linux. One is about 1.5 GB, and I believe it to be the swap space.

Correct

One contains a shedload of directories such as boot, dev, etc, home;

This is the root partition containing the main operating system files which you will replace when you reinstall.

the other contains only two directories, one named lost+found and the other named my username.
This is the home partition containing all data files that you keep and re-use. Mount this partition as /home during the new installation.

The one to format and start again with is the one with boot, dev and so forth on.
Right again – hat trick!

Regarding the terrorist in your motherboard – I don’t think it’s windows looking at the swap file. But if we never hear from you again – maybe it was.