Grub Error 22

I’ve just installed OpenSUSE 10.2 on my main pc (currently writing from a laptop). I installed the main repositories, did a complete online update, and fiddled a little with the network card (just making a static IP address). During that time I restarted it a few times to update the kernel etc and it was fine, showing the boot selection screen, but I’ve just restarted it again and I’ve been greeted with:

GRUB loading, please wait…
Error 22

I have OpenSUSE on one hard drive (10GB suse, 1 GB Swap, 6GB fat32) and Vista Ultimate on another one. I’ve read you can reinstall Grub or replace it with lilo but I don’t know if that would solve it. Until it’s fixed the computer is unusable.

Does anyone have any idea what I can do to get my selection screen back?

Hi,

According to Grub documentation:

22 : No such partition
This error is returned if a partition is requested in the device
part of a device- or full file name which isn’t on the selected
disk.

So, it is trying to get a file (kernel, ramdisk) whose location reference in menu.lst is probably broken or stated wrongly.

Could you please give us the content of your /boot/grub/menu.lst file and the output of fdisk -l?
For that, boot in rescue mode from the DVD drive.

Regards.

To do the above, you will need to login as root, and then use the cat command, and while you are there, it saves time to provide two other files, so altogether it’s:

fdisk -l -u
cat /boot/grub/menu.lst
cat /boot/grub/device.map
cat /etc/grub.conf

The boot loader and its configuration can be repaired from the Repair module on the DVD. We’ll know what specifically to advise when we see the above.

Also, from the boot menu are you also unable to boot Vista? Or are you booting Vista separately altogether, such as switching the boot device from a BIOS boot menu or the like?

For about the 4th time since it stopped working, I’ve just switched on the pc, and now it’s working again, I’ve no idea why!

I’ve left what I wrote below in case you can see if there’s something that could cause it to intermittently not work.

EDIT: Thanks for the instructions Mingus725, if the problem happens again I’ll post those files.


*Thanks for your help. This is what I get when I type fdisk -l when I use system rescue.

Disk /dev/hda: 123.5GB 123522416640 bytes
255 heads, 63 sectors/track, 15017 cylinders
Units = cylinders of 16065 8 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/hda1 * 1 15018 120625152 y hpfs/ntfs

Disk /dev/sda: 18.2GB, 18279045120 bytes
255 heads, 63 sectors/track 2222 cylinders
Unites = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/sda1 1 131 1052226 82 Linux swap / Solaris
/dev/sda2 132 1132 8040532+ 83 Linux
/dev/sda3 1133 2222 8755425 c W95 FAT32 (LBA)

Disk /dev/sdb: 131MB 131072000 bytes
16 heads, 32 sectors/track, 500 cylinders
Units =cylinders of 512 * 512 = 262144

Device Boot Start End Blocks Id System
/dev/sdb1 * 1 500 127984 b W95 FAT32
Partition 1 has different physical logical endings:
phys=(498 , 15, 32) logical=(499, 15, 32)

However I’m a bit of a (relative) novice with Linux and I’m not sure how to read files like /boot/grub/menu.lst in the console. Is there a simple command for it?

The contents of the menu.lst which I’ve just got is:

Modified by YaST2. Last modification on Wed Aug 20 18:08:19 BST 2008

default 0
timeout 8
gfxmenu (hd1,1)/boot/message

###Don’t change this comment - YaST2 identifier: Original name: linux###
title openSUSE 10.2 - 2.6.18.8-0.10
root (hd1,1)
kernel /boot/vmlinuz-2.6.18.8-0.10-default root=/dev/sda2 vga=0x31a resume=/dev/sda1 splash=silent showopts
initrd /boot/initrd-2.6.18.8-0.10-default

###Don’t change this comment - YaST2 identifier: Original name: failsafe###
title Failsafe – openSUSE 10.2 - 2.6.18.8-0.10
root (hd1,1)
kernel /boot/vmlinuz-2.6.18.8-0.10-default root=/dev/sda2 vga=normal showopts ide=nodma apm=off acpi=off noresume nosmp noapic maxcpus=0 edd=off 3
initrd /boot/initrd-2.6.18.8-0.10-default

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

###Don’t change this comment - YaST2 identifier: Original name: floppy###
title Floppy
rootnoverify (hd0,0)
chainloader (fd0)+1

That’s an unusual fdisk. What is the 131MB assigned drive name /dev/sdb? It appears linux is on /dev/sda. So Vista is on /dev/hda - note the “h” rather than a “s”, which is how linux assigns drive names on both IDE and SATA hung off motherboard controllers. This is the ~125GB Vista drive; is it on a PCI card or an external port or ?

I think the 131mb drive is a USB pen drive I accidentally left connected to the back of the pc while installing OpenSUSE. I’m not totally sure about the hard disk set-up in my PC as I had some trouble installing Vista and eventually let someone else do it.

So what is your booting status now; still need help?

There are several methods to booting with your set up, but first we need to know what the installation actually did and why. We would need to see the device.map and grub.conf files ref’d earlier. And, in the bios, which hard drive is configured as the first in the boot sequence?