Google Plus

How to reinstall Grub in linux

Written by Mel Kham on . Posted in Linux tutorials

This short Totorial shows you the snelest way to reinstall Grub

 

1- Boot off the LiveCD

2- Open a Terminal and type in the following command

su -c grub 

if doesen`t work try

sudo grub

This command will take you to the Grub prompt.

3- Now type the command bellow, this will return a location. If you have more than one, select the installation that you want to provide the grub files.

find /boot/grub/stage 

4- After type the command

root (hd0,0)

hd0,0 implies the first hard drive and the first partition on that drive,

IMPORTANT : Again use the value from the find command i.e. if find returned (hd0,1) then you would enter root (hd0,1)

5- type the command bellow  to install it on hd0, that is MBR of the first HD :

setup (hd0)

6- now exit

exit 

 

You will have to reboot your computer and remove your live cd, you should then find the grub back.

Please report if you encountred problems reinstalling Grub. Thanks

For questions please refer to our Q/A forum at : http://ask.unixmen.com

Mel Kham

Founder of Unixmen, Living in Amsterdam. Am working in my free time to help people to understand the Opensource and to explain them in easy way how to make the fist steps to the the light. Working day and night with my Co-founder Zinovsky to keep this website live even with less resources.
  • Hhorker

    that is what I get:
    grub> root (hd0.0)

    Error 11: Unrecognized device string

    grub> root (hd0,0)

    grub> setup (hd0)

    Error 17: Cannot mount selected partition

    grub> setup /dev/sda

    Error 11: Unrecognized device string

Like us on Facebook

This week Top Posts

Write for us

Recent Comments

Edson Carlos

|

In debian no found. I need link download install in linux debian

jacky can

|

You can actually unzip your secret archive by leaving out the -t option, instead using:

unzip newPhoto.jpg

DragonFartOutLoud

|

it went to china.

DragonFartOutLoud

|

great review! i’ve been using it as my main OS since Beta 1 release. its been a awesome ride so far :)

jet li

|

i try the method, and i unzip the image contain zip secret, i dont find the file that i was hide, where it go? and how to open it? :s

 
IDG Tech Network
Copyright © 2008-2013 Unixmen.com .
Maintained by Anblik .