How do I install Windows 7 alongside a pre-existing Ubuntu installation?

60,687

First, back up your data. Keep in mind, when installing an OS, over writing data is often a mouse click away.

Second, boot the ubuntu desktop CD, resize your partitions, and make a NTFS partition for Windows.

Then install Windows into the NTFS partitions. You may need to find drivers for your hardware.

Then boot the Ubuntu CD again and re-install grub. You can do this graphically with boot-repair

sudo add-apt-repository ppa:yannubuntu/boot-repair && sudo apt-get update
sudo apt-get install -y boot-repair && boot-repair

See https://help.ubuntu.com/community/Boot-Repair for details.

enter image description here

Share:
60,687
fedeisas
Author by

fedeisas

Updated on September 18, 2022

Comments

  • fedeisas
    fedeisas almost 2 years

    I purchased a PC six months ago for work related tasks. I do 95% of my work on Ubuntu (web development). Now, I want to install Windows on another partition to play a few games on my relax time. Which steps should I follow? Any suggestions? Every guide I found suggest to install Windows and, after that, Ubuntu. Being this my main development machine, I cannot afford the risk of wiping everything.

  • bioShark
    bioShark over 12 years
    Shouldn't sudo update-grub be enough? Why the need for the repair tool?
  • Panther
    Panther over 12 years
    You can install grub from the command line if you wish. I choose the graphical method is advised on the ubuntu wiki help.ubuntu.com/community/….
  • bioShark
    bioShark over 12 years
    It's not me with the issue, I'm just a bystander checking new ideas :). But all in all, good tip about the UI Tool.
  • Panther
    Panther over 12 years
    boot-repair seems popular, check it out. In addition to re-installing grub you can set a few options.
  • Bruno Pereira
    Bruno Pereira over 12 years
    boot-repair is the de facto tool for the job, if a user is asking how to install Windows after installing Linux a GUI tool is the way to go ;)
  • ultrajohn
    ultrajohn almost 11 years
    "Keep in mind, when installing an OS, over writing data is often a mouse click away." i learned this the hard way when I accidentally deleted the win8 partition on a laptop when I tried to install ubuntu. when there is a pre-existing os installed on your system, i recommend that your perform the partitioning of your disk yourself...