HOW TO : Recover Windows MBR using Ubuntu Live CD !!

bluX
04-22-2008, 06:46 AM
I guess this a really off topic thread but, I had been suffering from this problem and I thought maybe there will people like me facing this problem too. So this is why I'm posting it here too.

If you want to restore Windows Bootloader and for some reason cannot use the windows installation CD, there is a simple way to do it :

NOTE: make sure you have internet working.

1) Enable 'Universe' Repository :

To enable the 'Universe' Repository (System->Administration->Software Sources) and over there enable it.

NOTE : Before I could install the ms-sys package. I also needed to put "sudo" in front of the ms-sys command (e.g. "sudo ms-sys --mbr /dev/sda") or otherwise I got permission denied.

2) Boot with Ubuntu Live CD or Linux Mint Live CD

3) On the terminal :

Write these commands :

sudo apt-get install ms-sys

Then the following :

ms-sys --mbr /dev/hdX

NOTE : In my case the main windows xp system is located in hda1 so I used this command

sudo ms-sys --mbr /dev/hda

***
ubuntu@ubuntu:~$ sudo ms-sys --mbr /dev/hda
Windows 2000/XP/2003 master boot record successfully written to /dev/hda
***

4) Reboot.

This should get your windows back.

This guide is based on INOXLLOR , AJPROART & GONK's guide.

bluX
04-22-2008, 07:42 AM
So was it useful or not guys.

serjen
05-04-2008, 04:16 PM
loads easier tha going into the recovery version of windows using the boots CD, Great tut

bluX
05-07-2008, 09:32 AM
Ya brother you are right but sometimes people don't have the recovery CD some people like me so thats why and thanks for replying.