How do I reinstall Windows 7 while keeping my dual boot configuration? [duplicate]

Solution 1:

If you want to replace the old Windows 7 32-bit with a new Windows 7 64-bit installation, follow this procedure:

0. Edit volume label on existing Windows system

You should first boot to Windows and give a name to your windows partition. That will help you to identify the old Windows partition in the partitioning phase (described below).

1. Install Windows 7

  1. Insert the Windows 7 64-bit DVD and restart your PC.

  2. Press the appropriate keyboard button to enter into boot device selection menu. In Phoenix BIOS (used by Dell machines and some others as well), it is F12. If you press this button, you will be presented with some devices from which you can boot. Your DVD drive should be listed as one of the bootable devices.

    • Some BIOSes don't provide this boot device selection menu. In that case, you must enter the BIOS setup. To do so, Press F2 in a Phoenix BIOS. These key may be different on other BIOS. Some common keys are DEL, F2, and F12. There should be also a message telling you this kind of messages : "To change BIOS configuration, Press ...". Look at those messages and Try use that key.
  3. After booting to Windows 7 DVD, Go to the Installation phase. Select Custom Install option. Don't choose upgrade option.

  4. After accepting EULA and completing some other installation steps, you will be presented with the partitioning page. Click on Drive options (advanced), then select the previous Windows 7 partition. Choose to format the partition and then Click Next.

  5. Now a new Windows 7 64 bit will be installed replacing the old installation.

    Please note that Windows 7 64-bit will automatically replace the old one since you've chosen to format the old partition.

See these articles on Microsoft's website for help with Windows 7 installation:

  • Installing and reinstalling Windows
  • Installing a 64-bit version of Windows 7 on a computer running a 32-bit version of Windows

2. Re-install and repair GRUB using an Ubuntu live CD/DVD/USB

  1. Get a Ubuntu live CD/DVD or live USB. To have a CD, you just need to burn the .iso image to a blank CD:

    • How to burn or mount an ISO file? (has answers for both Ubuntu and Windows)

    • How to burn a CD on Ubuntu

    • How to burn a CD on Windows

    To get a Live USB, See these links:

    • How to create a bootable USB stick on Ubuntu

    • How to create a bootable USB stick on Windows

    • How can I make a Ubuntu Live USB with Ubuntu, GParted & HBCD?

  2. Boot the Ubuntu live CD/DVD or USB flash drive that you just created. Select the appropriate entry from the boot device menu in BIOS. Select the Try Ubuntu option (not Install Ubuntu) when you presented to choose an option.

  3. When the desktop comes up, reinstall and repair GRUB. Get help from the below links:

    • How can I repair grub? (How to get Ubuntu back after installing Windows?)

    Use this method if you don't have Internet connection in the live CD/DVD/USB system. But if you have a good, working Internet connection, this way is quicker.

    Note that in that answer, although it says to use GParted to see the partition's UUID, you can also use sudo blkid command for this.

Now, restart your PC from the menu at the upper-right corner of the live system's desktop. Remove the CD/DVD or USB flash drive when told to do so. (You don't want to accidentally boot from it again.) You should now have a machine with your original Ubuntu system and the newly installed 64-bit version of Windows 7 (which replaced the 32-bit version).


The essential difference between the installation of Windows 7 system while you already have Ubuntu (but not Windows) and installing a new Windows 7 system replacing an old one is, in the latter case you don't need to create and specify the partition for new Windows 7. You can just select the old Windows partition, select it to format and Click next to proceed to the installation. See this article for an official statement.

Solution 2:

You can install Windows as you should always do, but be sure of selecting the C:\ partition while installing (it should be tagged on the installer's partition editor with something as MASTER and should be NTFS) and formatting it for installing Windows there, but don't touch Ubuntu's partitions (swap or ext2/3/4).

After installing it, you should download SuperGrub2 disk. Burn it on a CD as you'd do with a linux distribution, and boot from it. Select Detect any operating system and select the entry where Ubuntu appears.

It will boot Ubuntu for you, because the GRUB was erased when you installed the new Windows 7. But with this you can boot to ubuntu! So, after booting ubuntu with SuperGrub, run a Terminal and enter this command:

sudo grub-install /dev/sda

(Changing /dev/sda for the place where you want to install grub, should be the MBR). Then, restart and, without booting from the SuperGrub CD that you won't need anymore, you'll see GRUB again, and it should have the Ubuntu entry and the Windows 7 entry.

I hope it works to you, and tell us soon!