Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am currently running a dual boot machine with Ubuntu 11.04 and Windows Vista.

Is there any way I can delete the Linux partition and Grub boot loader without affecting the Windows partition at all?

I would also like to be able to repartition all of the space that was previously occupied by Linux.

share|improve this question

migrated from Aug 30 '11 at 2:34

This question came from our site for professional and enthusiast programmers.

Prior to deleting the Linux partition, you must restore the MBR and boot sector. Try using the bootsect.exe command listed here:

d:\boot\bootsect.exe /nt60 all

(Where D: is your Vista install DVD)

After doing this, reboot, and confirm that the GRUB menu does not appear. If successful, you can then use disk management to delete the Linux partition, and resize the windows partition to fill the empty space.

share|improve this answer
One problem is with my actual boot loader, when reboot my computer goes straight into ubuntu – Shantanu Aug 30 '11 at 2:17
Yes, this is why you need to replace the MBR and boot sector, to remove the GRUB bootloader – bdonlan Aug 30 '11 at 2:20
For completeness, note that this presupposes one particular choice for dual booting, where GRUB2 chains to Microsoft Boot Manager. People do install things the other way around, in which case it is not necessary to do anything with the MBR at all. Which choice was made was not stated in the question, and answers are supposed to be for more than just one person's benefit. – JdeBP Aug 30 '11 at 3:41
@JdeBP, indeed, although if you replace the MBR/bootsector in that configuration it will do no harm, and you'll still be able to boot into Windows after killing the Linux partition – bdonlan Aug 30 '11 at 3:42

If linux is installed alone on its own partition(not sharing anything with windows)

You can right click on `My Computer >> Manage >> Disk Management

The steps to do it are explained in the link below. They are

1) Backup Linux files (if you want)

2) Delete Linux partitions (From Disk Management)

3) Restore Windows MBR from disc

4) Reclaim the free space

Get Rid of Linux from Dual Boot machine

share|improve this answer
Whoa, hold on there, you need to replace the MBR first or you won't be able to boot after this. – bdonlan Aug 30 '11 at 2:06
Yes thats why I googled, I did forget that. Its mentioned in my link – sealz Aug 30 '11 at 2:06
I think this will cause trouble, as the Bootloader is not rewritten. It might break! – bitmask Aug 30 '11 at 2:08
To clear things up. I have deleted before and then restored. But to be safe I would follow bdonlan's answer. It is possible to end up with nothing bootable. – sealz Aug 30 '11 at 2:09

Your Answer


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