LinuxQuestions.org
Register a domain and help support LQ
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 11-04-2010, 05:52 PM   #1
Conanu
LQ Newbie
 
Registered: Nov 2010
Posts: 3

Rep: Reputation: 0
Ubuntu Grub error 22


Help Please!

I had Ubuntu and Windows running on my computer. Ubuntu had an error such that I could not load it, so I wanted to delete Ubuntu via Windows. I followed the directions found here: http://bobmorris.wordpress.com/2008/...-windows-only/

++++
1) In Windows, launch Disk manager and remove every partition used by Ubuntu (root partition, swap, …)
2) Reboot with your Windows CD. When asked, choose “repair” and launch fixmbr. This command replaces GRUB with Windows bootloader.
3) Reboot again and you have done.

Once you are done, it you want to recover the space for Windows that was once used by Ubuntu. You can use the steps outlined above (going the the Disk Manager, etc). To create a new NTFS partition and assign it as something like the D: drive (or some other letter) to be used for data and so forth.
++++

However, I think I neglected to delete one of the 3 Ubuntu drives, which MAY have caused the following problem:

When I try to run the repair function on the Windows re-installation CD, it says that it cannot find any hard drive on my computer, and therefore can't run the repair.

It then restarts the computer, and I get Grub 1.5 Error 22.

Any ideas on how to fix this so I can just run Windows again?

Thanks!
 
Old 11-04-2010, 07:33 PM   #2
bigrigdriver
LQ Addict
 
Registered: Jul 2002
Location: East Centra Illinois, USA
Distribution: Debian Jessie 8.4
Posts: 5,873

Rep: Reputation: 348Reputation: 348Reputation: 348Reputation: 348
Quote:
Grub Error 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.
The first part of Grub, which is in the MBR, is simply telling you that the partition in which the rest of Grub is located, can't be found at the address given in the Grub config file.

As to the problem of not being able to find the windows partition, I suggest that you boot the Ubuntu installation cd as a live cd. Then, when Ubuntu is running, open a terminal and run, as root, fdisk -l. If the windows partition still exists, fdisk will show it to you. You should be able to mount the partition and inspect the contents to be assured that windows is still there and should be bootable.

Since you are getting an error with the windows install cd which tells you it can't find a partition on your hard drive, I have to wonder if you didn't inadvertently delete the windows partition along with Ubuntu.
 
Old 11-05-2010, 02:14 PM   #3
Conanu
LQ Newbie
 
Registered: Nov 2010
Posts: 3

Original Poster
Rep: Reputation: 0
Thanks bigrigdriver.

So I ran ubuntu from disk, and opened up gparted.

The partitions are:

Partition-File system-size-flags
/dev/sda1 ntfs 68GB boot (this is all of my windows files, and presumably the operating system)
/dev/sda2 extended 16GB (these are the partitions I deleted, thinking it was ubuntu)
---->unallocated unallocated 16GB
/dev/sda3 fat32 7.45 GB iba (this is the windows recovery partition)
/dev/sda4 ntfs 1 GB (not sure what this one is)

I can't seem to mount any of the drives using gparted (Partition -> Mount is unavailable, though UNmount is available).

Can you tell from this information what's what, or let me know what the next step might be?

Thanks!
 
Old 11-05-2010, 02:39 PM   #4
Conanu
LQ Newbie
 
Registered: Nov 2010
Posts: 3

Original Poster
Rep: Reputation: 0
Sorry,

Was able to mount the partitions, and all windows files appear to be there.

I can also open the windows recovery partition.

Thoughts?
 
Old 11-05-2010, 03:14 PM   #5
btncix
Member
 
Registered: Aug 2009
Location: USA
Posts: 141

Rep: Reputation: 26
I assume you don't care about /dev/sda2 any more.

0. back up your files
1. You can create a new primary partition on /dev/sda2 and create a ext3 file system on it.
2. Then you can install grub legacy or grub2 onto /dev/sda2 - I recommend grub legacy
3. setup grub legacy or grub2 to chainload Windows (I assume it's /dev/sda1 in this case?)
4. reboot and try to boot into Windows via grub legacy / grub2
5. If you can boot into Windows, try to recover the Windows system internally.


The steps above will be easier if you can work with grub legacy instead of grub2. Can you download and burn a different live rescue CD besides the Ubuntu live CD. I think SystemRescueCD or Parted Magic are good ones.


Ignore below for now, but keep it in mind for later:
-----------------------------------------------------
I don't know if you can modify the live Ubuntu system, but you can try to remove grub2 and install grub legacy. Here's the guide. You will need to translate it through Google translate to understand it.

Last edited by btncix; 11-05-2010 at 03:16 PM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Ubuntu 7.10 Dual Boot with XP, ubuntu partition deleted, grub 1.5 error 22 narchy Linux - Newbie 11 02-07-2011 04:54 AM
GRUB Error 26: Disk Read Error (using grub4dos and ubuntu) Dark_Master Linux - Software 11 02-25-2007 08:42 AM
GRUB Error 26: Disk Read Error (using grub4dos and ubuntu) Dark_Master Linux - Newbie 2 11-07-2006 12:58 PM


All times are GMT -5. The time now is 06:52 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration