LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   reinstalling GRUB (https://www.linuxquestions.org/questions/linux-newbie-8/reinstalling-grub-403634/)

vineet7kumar 01-15-2006 11:48 AM

reinstalling GRUB
 
how to reinstall grub if it's corrupted by a windows boot disk??
some of my frndz faced this problem?
thanx,
vineet

saikee 01-15-2006 12:02 PM

You boot up a Linux Live CD, make a directory on /mnt, mount the unbootable Linux partition on it, change root to the unbootable Linux, do a Grub-install, exit and reboot.

As example if the root partition of your Linux is hda6, after boot up a Live CD (almost any one will do)
Code:

mkdir /mnt/temp
mount /dev/hda6 /mnt/temp
chroot /mnt/temp
grub-install /dev/hda
exit
reboot

If you use a Sata the hda6 should be sda6 and hda should be sda.

hda without the partition number means the whole disk and that is the MBR.


All times are GMT -5. The time now is 06:28 PM.