- Boot your computer with the Ubuntu CD
- Go through the installation process until you reach "[!!!] Disk Partition"
- Select Manual Partition
- Mount your appropriate linux partions:
- DO NOT FORMAT THEM.
- Finish the manual partition
- Say "Yes" when it asks you to save the changes
- It will give you errors saying that "the system couldn't install ....." after that
- Ignore them, keep select "continue" until you get back to the Ubuntu installation menu
- Jump to "Install Grub ...."
- Once it is finished, just restart your computer
From:
http://doc.gwos.org/index.php/Restore_Grub and
http://ubuntuforums.org/showthread.php?t=76652
Don't forget that this method, as described, puts GRUB back on the MBR (master boot record) of the hard drive instead of in the root parititon. This is fine for most people, but not if you already have an alternative boot manager.
In other words, if you use something like Boot Magic or System Commander, the commands you've just read will overwrite what you've got.
If you've installed GRUB into the Root Partition instead of the MBR, the commands are a little different. Here's are the instructions that I have for my system:
How to Restore the Grub Menu after a Re-Ghosting:
1. Boot from a Live CD, like Ubuntu Live, Knoppix, Mepis, or similar.
2. Open a Terminal. Open a root terminal (that is, type "su" in a non-Ubuntu distro, or "sudo -i" in Ubuntu). Enter root passwords as necessary.
3. Type "grub" which makes a GRUB prompt appear.
4. Type "find /boot/grub/stage1". You'll get a response like "(hd0)" or in my case "(hd0,3)". Use whatever your computer spits out for the following lines.
5. Type "root (hd0,3)".
6. Type "setup (hd0,3)". This is key. Other instructions say to use "(hd0)", and that's fine if you want to write GRUB to the MBR. If you want to write it to your linux root partition, then you want the number after the comma, such as "(hd0,3)".
7. Type "quit".
8. Restart the system. Remove the bootable CD.
From:
http://ubuntuforums.org/showpost.php?p=121355&postcount=5
1. Pop in the Live CD, boot from it until you reach the desktop.
2. Open a terminal window or switch to a tty (Ctrl + Alt + F1).
3. Type "sudo grub"
4. Type "root (hd0,6)", or whatever your harddisk + boot partition numbers are (my /boot is at /dev/sda7, which translates to hd0,6 for grub).
5. Type "setup (hd0)", ot whatever your harddisk nr is.
6. Quit grub by typing "quit".
7. Reboot.
From:
http://ubuntuforums.org/showpost.php?p=117829&postcount=2