Okay, after fighting with this myself for the past few days, I thought I'd post some specfics on how to accomplish this, since I've been messing about with this for the last 3 days, there may be a step or 2 missing, please report back if this doesn't work for you.
In my case this is on an Asus EEE PC netbook, with windows installed in
Unbuntu is installed in
/dev/sda7 (single root partition)
Currently when machine is started it boots right into windows with no option for linux.
1) boot karmic live CD
no problem there, however I open a terminal and type "sudo -s" so I don't have to keep typing sudo before any of the commands below.
2)read MBR to file1 (with dd, iniital 512 bytes of disk)
I mounted a sdcard as /media/scdard1
dd if=/dev/sda of=/media/sdcard1/xp.mbr bs=512 count=1
note, to verify you have a proper file (my first attempts came out blank), run
it the result is all zeros you did it wrong, you should see lots of hex codes and in the asci text to the right you see mention of missing operating system and things like that.
3) mount karmic partition and /dev and chroot to it (hints how to do it without chroot did not work for me! so don't waste your time)
chroot is NOT necessary, however you will have to mount the root partition, in my case
mount /dev/sda7 /media/sda7
NOTE: when a friend and I were looking at this, we found that the stage1, stage1_5 and stage2 files were missing from /boot/grub directory, I had to manually copy them (from memory) from /usr/share/grub, this might not be necessary.
4) reinstall grub, this time to MBR (!) ("grub-setup /dev/sdx" is enough)
based on #3
grub-install --root-directory=/media/sda7 /dev/sda
if you reboot at this point, grub should come up, since I didn't have a menu.lst file setup, I had to type the following to load it up, taken pretty much verbatim from the Grub Grotto site at
This is what I added to my menu.lst file
grub> root (hd0,6)
grub> kernel /vmlinuz root=/dev/sda7
title Ubuntu 9.1.0
kernel /boot/vmlinuz-2.6.31-14-generic root=/dev/sda7
5) read MBR to file2
again using mounted sd card
dd if=/dev/sda of=/media/sdcard1/ubuntu.mbr bs=512 count=1
6) reinstall MBR from file1
dd if=/media/sdcard1/xp.mbr of=/dev/sda bs=512 count=1
7) give file2 to NTLDR (boot.ini)
as per this slashdot article
I enter the following at the bottom of boot.ini
C:\ubuntu.mbr = "Ubuntu 9.1.0"
copy the ubuntu.mbr file to the root of c: drive
8) reboot, now the NTloader menu has both a windows and a linux option, choosing the linux option, gets you to the grub menu and a few seconds later boots up Ubuntu