Firstly I installed Windows XP, secondly Linux Ubuntu. Grub erased Windows boot record. How to restore Windows XP boot record? Which command to use?
3 Answers
Boot with your windows CD into the recovery console. Issue fixmbr
. Reboot. There you go.
Under Ubuntu there are two tools (that I know about) to install windows master boot record. First is mbr
. You can install it with sudo apt-get install mbr
. The second and in my opinion superior is ms-sys.
But you need to compile it. Simply download, unpack, and install with sudo make install
(reading README wouldn't hurt also). Then type ms-sys --help
to choose your mbr type.
For Windows XP it is
sudo ms-sys --mbr /dev/your_device
and for Windows 7:
sudo ms-sys --mbr7 /dev/your_device
You can simply use a chainload without installing the windows first stage boot loader into the mbr. Take a look at this for further information.