Grub Error 22

Hi all,

I’m dual-booting Windows 7 and Suse 11.3, installing suse second on a seperate 80GB drive.

After a ridiculous amount of faffing around due to my dvd writer essentially not working, finally get suse installed, messing with GRUB settings in an attempt to preserve Windows’ boot manager, restart; GRUB error 22.

Go through the whole process again, this time accepting the use of grub and not changing anything from default - exactly the same response. None of the tens of boot disks/utilities I’ve tried will allow me into suse to have a look at the grub config. There are no applications for windows that will allow me to write to ext3.

It’s no mystery as to why Linux isn’t taking more of the market…

Any suggestions would be greatly appreciated.

On 2011-02-12 03:06, Fowlet wrote:

> error 22.

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.

> It’s no mystery as to why Linux isn’t taking more of the market…

This comment here will not encourage us to help you a lot…


Cheers / Saludos,

Carlos E. R.
(from 11.2 x86_64 “Emerald” at Telcontar)

Hi all,

I’m dual-booting Windows 7 and Suse 11.3, installing suse second on a seperate 80GB drive.

After a ridiculous amount of faffing around due to my dvd writer essentially not working, finally get suse installed, messing with GRUB settings in an attempt to preserve Windows’ boot manager, restart; GRUB error 22.

Go through the whole process again, this time accepting the use of grub and not changing anything from default - exactly the same response. None of the tens of boot disks/utilities I’ve tried will allow me into suse to have a look at the grub config. There are no applications for windows that will allow me to write to ext3.

It’s no mystery as to why Linux isn’t taking more of the market…

Any suggestions would be greatly appreciated.
Fowlet, when you install openSUSE and allow it to create its own setup, it almost always works. If you decide to modify the installation setup, then you need to know what you are doing. openSUSE uses the Grub Operating System Selection Menu. It has a boot loader that can be installed into the MBR (Master Boot Record) or into any one of the first four primary partitions. What ever disk you install grub onto, it is best or even required (depending on what you did) to have both Grub and the openSUSE partition on the same hard drive. If I intended to install openSUSE onto a second hard drive, then first you must be able to select that hard drive as the boot drive in your BIOS, you need to modify the boot loader to load onto the second hard drive and you need to make sure the boot order is not based on hardware order, but based on the how you have selected the new boot drive. If you do not understand what this means then perhaps you should have let the grub boot loaded do its on thing and accepted it or you needed to learn more about how Linux works first. When compared to Windows that always must be loaded first and in the first partitions, Linux can be loaded onto any drive or partition and made to work, but does require more expertise than required to load Windows first. Of course if you loaded openSUSE first, it would have worked just fine as well.

Thank You,

That’s a good thing. :wink:

With Linux, we’re free to access dozens of file systems; with Windows, we’re limited to what Microsoft spoon-feeds us.

Some people love freedom, and are willing to work for it. Others – probably the vast majority – find freedom frightening and aspire to be no more than corporate slaves. Mystery solved.

Start with a simple one-disk configuration with a basic Linux system. The more you use Linux, the more you’ll like it. Eventually, you’ll be ready to delete that obsolete Windows partition. That will simplify things.

First of all, thank you for all of your responses - the huge upside to most linux distros is strength of community! Apologies for my tone last night; I was an angry, angry man.

For those thinking I’m still messing with the grub install, I’m not: the second time, I left everything as default.

I’m beginning to suspect the problem is, as suggested, the numbering of harddisks differing. As a side note, I can no longer get into Windows 7, which I do need.

I’ve used the ultimate boot cd to get to the grub prompt, and worryingly “find menu.lst” is returning “file not found”.

As for why I need Windows 7; I’m a systems engineer. NI Multisim, MATLAB, Solidworks… and of course video games lol!

So, is the grub “find” command infallible? Do I really not have any “menu.lst” anywhere on any partition grub can read?

First of all, thank you for all of your responses - the huge upside to most linux distros is strength of community! Apologies for my tone last night; I was an angry, angry man.

For those thinking I’m still messing with the grub install, I’m not: the second time, I left everything as default.

I’m beginning to suspect the problem is, as suggested, the numbering of harddisks differing. As a side note, I can no longer get into Windows 7, which I do need.

I’ve used the ultimate boot cd to get to the grub prompt, and worryingly “find menu.lst” is returning “file not found”.

As for why I need Windows 7; I’m a systems engineer. NI Multisim, MATLAB, Solidworks… and of course video games lol!

So, is the grub “find” command infallible? Do I really not have any “menu.lst” anywhere on any partition grub can read?
So I dual boot with Windows all of the time and it works just fine. I must ask if the computer in question boots into anything now? How are you getting online now? To be able to help, we need to know something about your partition setup and something about the computer you are trying to install openSUSE on to. As an example, here might be your thought to be partition setup:

Hard Disk 1, xxxx GB in Size, Internal SATA, normally called /dev/sda

  1. sda1 - Windows 7 boot partition - 250 mb
  2. sad2 - Windows 7 main partition - xxx GB

Hard Disk 2, xxxx GB in Size, External USB, normally called /dev/sdb

  1. sdb1 - Linux swap - 8 GB
  2. sdb2 - Linux / - 20 GB - Grub loaded here and is marked active for booting
  3. sdb3 - Linux /home - 56 GB

Then, if you wanted to boot from /dev/sdb did you select it as your boot drive in your BIOS setup? Did you get a Windows 7 boot disk? You can boot from their disk and repair most Windows 7 installations and get them working again.

Thank You,

On 2011-02-12 14:36, Fowlet wrote:

> So, is the grub “find” command infallible? Do I really not have any
> “menu.lst” anywhere on any partition grub can read?

Boot a linux live CD, run and paste results here (as code⁽¹⁾):

Code:

fdisk -l

file -s /dev/sd*

(http://en.opensuse.org/All_About_Grub)

(1) View this thread: http://forums.opensuse.org/showthread.php?t=451526


Cheers / Saludos,

Carlos E. R.
(from 11.2 x86_64 “Emerald” at Telcontar)

Ok, reinstalled from liveUSB, all default settings (except told it i didnt want a seperate “/home” partition), same error on restart.

Booted using a liveUSB, tried to use YAST’s boot configuration, said due to partitioning it couldn’t do it’s thang…

Here’s the contents of /boot/grub/menu.lst:

Modified by YaST2. Last modification on Sat Feb 12 13:39:40 GMT 2011

THIS FILE WILL BE PARTIALLY OVERWRITTEN by perl-Bootloader

Configure custom boot parameters for updated kernels in /etc/sysconfig/bootloader

default 0
timeout 8
gfxmenu (hd1,1)/boot/message
##YaST - activate

###Don’t change this comment - YaST2 identifier: Original name: linux###
title openSUSE 11.3
root (hd1,1)
kernel /boot/vmlinuz-2.6.34-12-desktop root=/dev/disk/by-id/ata-ST3808110AS_5LR69LSS-part2 resume=/dev/disk/by-id/ata-ST3808110AS_5LR69LSS-part1 splash=silent quiet showopts vga=0x345
initrd /boot/initrd-2.6.34-12-desktop

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

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

###Don’t change this comment - YaST2 identifier: Original name: Linux other###
title Linux other
rootnoverify (hd3,0)
chainloader +1

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

###Don’t change this comment - YaST2 identifier: Original name: failsafe###
title Failsafe – openSUSE 11.3
root (hd1,1)
kernel /boot/vmlinuz-2.6.34-12-desktop root=/dev/disk/by-id/ata-ST3808110AS_5LR69LSS-part2 showopts apm=off noresume edd=off powersaved=off nohz=off highres=off processor.max_cstate=1 nomodeset x11failsafe vga=0x345
initrd /boot/initrd-2.6.34-12-desktop

And here’s the results of fdisk -ls as superuser:

Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x94f3dab7

Device Boot Start End Blocks Id System
/dev/sda1 1 60801 488384001 7 HPFS/NTFS

Disk /dev/sdb: 80.0 GB, 80026361856 bytes
255 heads, 63 sectors/track, 9729 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x0006b546

Device Boot Start End Blocks Id System
/dev/sdb1 1 262 2103296 82 Linux swap / Solaris
Partition 1 does not end on cylinder boundary.
/dev/sdb2 262 8748 68156416 83 Linux
/dev/sdb4 8748 9730 7889920 c W95 FAT32 (LBA)

Disk /dev/sdc: 163.9 GB, 163928604672 bytes
255 heads, 63 sectors/track, 19929 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x8deb0bed

Device Boot Start End Blocks Id System
/dev/sdc1 * 1 19929 160079661 7 HPFS/NTFS

Disk /dev/sdd: 4009 MB, 4009754624 bytes
64 heads, 32 sectors/track, 3824 cylinders
Units = cylinders of 2048 * 512 = 1048576 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x86304a82

Device Boot Start End Blocks Id System
/dev/sdd1 * 1 695 711680 83 Linux
/dev/sdd2 696 3824 3204096 83 Linux

Disk /dev/sdd1: 728 MB, 728760320 bytes
64 heads, 32 sectors/track, 695 cylinders
Units = cylinders of 2048 * 512 = 1048576 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x86304a82

 Device Boot      Start         End      Blocks   Id  System                

/dev/sdd1p1 * 1 695 711680 83 Linux
/dev/sdd1p2 696 3824 3204096 83 Linux

Disk /dev/sde: 640.1 GB, 640135028736 bytes
255 heads, 63 sectors/track, 77825 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x9e83813b

Device Boot Start End Blocks Id System
/dev/sde1 1 77825 625129281 7 HPFS/NTFS

Does this shed any light?

Sorry jdmcdaniel3, posted before I saw yours, does my post help anyway?

EDIT: Didn’t see your post either Robin, seems I stumbled along the right lines anyway!

It does help and confirms that you loaded openSUSE onto /dev/sdb and if Windows 7 does not boot, you have loaded the grub boot loader into the MBR of /dev/sda while trying to load openSUSE from /dev/sdb2 which does not allow either to work.

  1. To get Windows back to working, you will need a Windows boot disk or some sort of MBR utility. I found one called Mater Boot Sector that only cost $5, but you have to have a working copy of Windows 7 and the Windows SDK (which you can get for free) to make their boot disk. Most people just use the repair option in the Windows 7 boot disk to get Windows working again.

  2. If you want to boot openSUSE from a second (or higher hard drive), you must be able to select this hard drive as the boot disk in your BIOS setup. You need to modify the BOOTING section of the openSUSE installation to load the GRUB boot loader into the openSUSE root partition /dev/sdb2, you need to load the Generic MBR for booting the active partition, you need to set the openSUSE partition as the active partition, you need to change the hard disk boot order so that sdb is the first boot disk (because you made it the first boot disk in your BIOS).

  3. Lastly, you can abandon your desire to load openSUSE onto the second hard drive and allow the Windows partition to be reduced in size by 40 GB or so, load the GRUB boot loader into the MBR and create a 4 GB SWAP and a 36 GB root / which also includes /home and see if that works for you. This should get the Windows 7 partition booting again, but you may need to ask for advice on which menu.lst entry actually boots Windows. Every NTFS partition gets a grub menu.lst entry even if there is nothing there you can boot.

Thank You,

On 2011-02-12 15:36, jdmcdaniel3 wrote:

> 3. Lastly, you can abandon your desire to load openSUSE onto the second
> hard drive and allow the Windows partition to be reduced in size by 40
> GB or so,

A small 250 MB partition for /boot would suffice. The rest could still be
in the second disk.


Cheers / Saludos,

Carlos E. R.
(from 11.2 x86_64 “Emerald” at Telcontar)

Ok, fixed the MBR by extracting only the needed boot files from and W7 ISO, got back into Windows 7.

Found a free third-party project called EasyBCD that edits the W7 boot manager, added an entry that claimed to automatically find any GRUB installations… and on reboot it did!

Slight hiccough in that GRUB claimed it couldn’t boot, but now that I had the actual grub menu, I could press “e”, edit the line, change “root” to (hd2,1) intead of (hd1,1) and it boots!

So now I’m going to make that change permanent, change the grub timeout to zero, and I’ll basically be using W7’s boot manager to get into either W7 or linux.

Thanks for all of your help guys! I’m sure I’ll need more help soon…

Ok, fixed the MBR by extracting only the needed boot files from and W7 ISO, got back into Windows 7.

Found a free third-party project called EasyBCD that edits the W7 boot manager, added an entry that claimed to automatically find any GRUB installations… and on reboot it did!

Slight hiccough in that GRUB claimed it couldn’t boot, but now that I had the actual grub menu, I could press “e”, edit the line, change “root” to (hd2,1) intead of (hd1,1) and it boots!

So now I’m going to make that change permanent, change the grub timeout to zero, and I’ll basically be using W7’s boot manager to get into either W7 or linux.

Thanks for all of your help guys! I’m sure I’ll need more help soon…
That is FANTASTIC News Fowlet and a little different from your original thoughts on the subject. I might even suggest you make a write up on what you did to recover Windows and get Grub booting again (Make it a detailed report and your best work). We see lots of people with that problem that would like to see your solution. You can post any of your efforts here:

Unreviewed How To and FAQ

If it is good I will give you a plug, though consider that my plug and .25 cents will still fall short of buying a cup of coffee. Now consider that you do this not only for others but for yourself as well. Something to refer to later should it happen again (if we can assume you printed it out or could find it again online). Anyway it is just a thought on the subject.

And if I did not say so before: Welcome to the openSUSE Forums!

Thank You,