Reinstall grub after installing windows xp or windows 7

Start an ubuntu live system

Locate your linux partition

fdisk -l

Lets assume that your linux installation is in /dev/sda1 and that you want to install grub into the master boot sector of /dev/sda

mount your ubuntu partition

mount /dev/sda1 /mnt/sda1

install grub

grub-install --root-directory=/mnt/sda1 /dev/sda

boot into your system and update the menu

sudo update-grub

Ref: http://www.ubuntugeek.com/how-to-restore-grub-boot-loader-after-installing-windows.html

~~LINKBACK~~

Enter your comment. Wiki syntax is allowed:
If you can't read the letters on the image, download this .wav file to get them read to you.