Just a few minutes ago, I got a HFS+ Partition Error while trying to boot into my OS X. So, I decided to mess with it a little bit. Actually, I reinstalled OS X and messed around some more (the whole process took 3 hours). Somehow, my Grub was gone after the reinstallation. There went my beloved boot manager, who had saved me so many times. I went right to the first stage of grief, denial. I put my Ubuntu live CD in, loaded Firefox on and search for the solution. Folks at Ubuntuforum.org had found the solution years ago. So I just summed everything up, it’s all their credits. (If you are not a member of Ubuntuforum.org join now! it’s awesome.)
Restoring Grub with a Ubuntu Live CD.
You are going to need the Ubuntu Live CD.
- Insert the Live CD and boot into Graphic Mode.
- Open Terminal: Applications -> Accessories -> Terminal
- Enter the Grub Shell.
sudo grub
- Look for your grub files location.
find /boot/grub/stage1
- The returned value from the command above is used for the command below. Scan the partition.
root (hd?,?)
- Now, we reinstall Grub.
setup (hd0)
- Quit Grub.
quit
- Close Terminal and Restart. Grub will starts back again.
Substitute the returned value into (hd?,?) above. For instance, if my returned value is (hd0,2), I will enter:
root (hd0,2)
I took a snap shot of this whole process. Take a look.
Filed under: Ubuntu | Tagged: grub, restore grub, Ubuntu |
Thanks