LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Recovering grub (https://www.linuxquestions.org/questions/linux-newbie-8/recovering-grub-562437/)

almon 06-17-2007 11:12 AM

Recovering grub
 
I reinstalled windows and lost grub.I want to boot into linux but after many attempts I m not able to recover grub....help
My fdisk command gives this output:

Disk /dev/sda: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/sda1 * 1 1305 10482381 c W95 FAT32 (LBA)
/dev/sda2 1306 19456 145797907+ f W95 Ext'd (LBA)
/dev/sda5 1306 6404 40957686 7 HPFS/NTFS
/dev/sda6 6405 11503 40957686 7 HPFS/NTFS
/dev/sda7 11504 12721 9783553+ 7 HPFS/NTFS
/dev/sda8 * 12722 13994 10225341 83 Linux
/dev/sda9 13995 14053 473886 82 Linux swap / Solaris
/dev/sda10 14054 16602 20474811 7 HPFS/NTFS
/dev/sda11 16603 19456 22924723+ 7 HPFS/NTFS
root@ubuntu:/home/ubuntu#

Now tell me what should i do in order to recover grub???

serafean 06-17-2007 11:22 AM

Hi,

Simply chroot into your existing installation from a liveCD, and install grub manually
Code:

#mount /dev/hdxy /mnt/***
#chroot /mnt/*** /bin/bash
#grub
>root (hdx,y)
>setup (hdx)
>quit

replace *** by the folder to which you mounted the root partition of the existing installation
replace x by the hard disk number/letter (the first being 0/a)
replace y by the partition number (the first being 0)

Emerson 06-17-2007 11:25 AM

Double post ... you have similar thread in General. Usage of words like "please" and "thank you" is encouraged in western world.


All times are GMT -5. The time now is 05:02 AM.