Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I am confused, so I am also going to use this question to get clarification and fix my computer.

Some background: I had Windows 7 on a 1 TB HDD and decided to partition my hard drive into two ~500 GB partitions, one for Windows 7 and one for Ubuntu or whatever flavour I desired (like a sandbox partition...)

I installed Ubuntu but the installation had issues so I decided to uninstall. Note before the uninstallation I had to press f12 when I turned on to boot from my primary HDD, then choose what OS I wanted to use. Undesirable, but it worked.

Anyway, after I decided to uninstall Ubuntu I went into Windows 7 > Start > Computer > Manage and deleted the EXT4 filesystem (Ubuntu partition) giving me 4xx GB of free space. However when I restarted Windows 7, I am now unable to boot Windows.

When I DON'T hit F12, I see a blank screen with a flashing underscore. When I DO hit F12, I choose my primary HDD, and then I get a GRUB error:

Unknown filesystem:

grub rescue> _

Something I'm unclear of: GRUB boots linux partitions, right? What boots Windows? Is GRUB "overwriting" the Windows bootloader? How can I completely get Windows back to normal? (IE, It boots automatically without hitting F12.)

Thanks for any help, I'm on a live CD version of Ubuntu right now until I can get back on Windows.

share|improve this question
add comment

6 Answers

GRUB works in stages. First part of it is loaded from MBR (Master Boot Record), which points to secondary data located on your Linux partition that is required to proceed with next step of grub. From your description of the problem, apparently you have deleted the second stage of your grub installation and grub isn't able to find it.

In order to get back your Windows 7 boot loader on your MBR, to allow you to boot into Windows 7, follow these steps:

1- Boot your computer from your Windows 7 install dvd.

2- Choose your language, time, and keyboard input on the first screen, and click next.

3- On next screen, you will be presented with three choices. Click on "Repair Your Computer", to enter recovery window. Now select "Command Prompt". At the command prompt, first change your directory to boot (cd boot), and then type "bootsect /nt60 C:\". This will restore your windows boot loader onto your MBR.

Now restart your computer, and you should be able to boot into your Windows 7 installation.

share|improve this answer
    
Just one problem, I don't have an installation disk, the OS came on the computer. –  Sam J Apr 3 '11 at 4:10
    
For future reference, you can find a safe win 7 ISO online. See this question: http://superuser.com/questions/78761/where-do-i-download-windows-7-legally-from‌​-microsoft. –  Hennes Sep 2 '13 at 14:11
add comment

Since you don't have the installation disk, reinstall Ubuntu. This will fix GRUB and you'll back up and running.

After you have done this, you can make a recovery disk in Windows, from which you should be able to reinstall the Windows MBR (Master Boot Record). Don't delete the Ubuntu partition until you can boot directly into Windows without going through GRUB.

The simplest solution would be to find a disc (borrow it from someone), but this should work.

share|improve this answer
add comment

If you are no longer using ubuntu, why don't you use Windows Install CD and use fixboot and fixmbr commands. more info here: http://support.microsoft.com/kb/927392 or google

share|improve this answer
add comment

@tjameson: You don't need to reinstall Ubuntu if you have the live CD running - just reinstall GRUB to the Linux partition.

Instructions for GRUB 1 can be found here, or for GRUB 2 there's a fairly exhaustive guide here. Which to install would depend on how old your Ubuntu version is.

share|improve this answer
    
When I boot from the Ubuntu CD, like it says in the GRUB 1 tutorial and enter "sudo grub" I get sudo: grub: command not found. –  Sam J Apr 3 '11 at 15:10
    
You probably have GRUB 2. Look at section 13 of the GRUB 2 guide. –  user55325 Apr 4 '11 at 23:27
    
@user55325 Reinstalling Ubuntu will at least give him a backup so he can run update-grup or something if installing GRUB doesn't work. And it takes forever to boot to the LiveCD if he has to do it a couple times. –  tjameson Apr 6 '11 at 9:33
add comment

If u had finally removed any other OS and do have windows(OS) then you can select c:\windows after booting from cd in cmd and type the following command chkdsk \recovery Your hard drive will be automatically set to windows and will boot from it. But this process will take around 45 minutes.

This is not only for that but even if windows shows error of unknown on C: drive and all the reserved space is empty than also select this it will restore your windows.

share|improve this answer
add comment

Put the Windows 7 installation/Upgrade disc in the disc drive, and then start the computer (set to boot from CD in BIOS).

Press a key when you are prompted.

Select a language, a time, a currency, a keyboard or an input method, and then click Next.

Click Repair your computer.

Click the operating system that you want to repair (Windows 7 in this case), and then click Next.

In the System Recovery Options dialog box, click Command Prompt.

Once in the command prompt, type exactly Bootrec.exe /FixMbr and then press ENTER. You will see "operation completed successfully." (Doesn't even take a second. Don't be alarmed )

Reboot and set BIOS to boot from the HDD again.

GRUB will be overwritten in step 7 and Windows bootloader will once again take control of loading your OS(s).

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.