Sign-in / Sign-up
Your question

Ubuntu first then Windows 7

Tags:
  • Windows 7
  • Ubuntu
Last response: in Open Source Software
September 16, 2011 5:42:25 PM

Hello,

I have a laptop with Ubuntu on it and an already partitioned hard drive.
If I want to install Windows 7 on the other, blank partition, and have dual boot, how should I proceed. Are there any big gotyas?

With many thanks!

More about : ubuntu windows

September 17, 2011 12:41:21 AM

Yes, there's a gotcha: Windows will clobber the master boot record (or MBR) which contains the early boot code used to bring up a system.

You can:
>Save the MBR as it exists now (le link, in this case you'd need to re-run update-grub to get Windows to show up in the boot menu)
>Boot into a linux disk of some sort, either a disc meant for recovering GRUB(2) (le link) or using the Ubuntu installation disc itself (le link)
November 1, 2011 7:40:25 AM

I would suggest option 2, and in the future, it's always easier to install Windows first.

If you're restoring the MBR, as described for option 1, and have changed the partitioning, you'll want to use "bs=446" instead of "bs=512" during the restore. The first 446 bytes store the boot code and the last 66 bytes store the partitioning and MBR signature. It doesn't hurt anything to backup the full 512 bytes though, and there are programs that will find your partitions again if needed.