Grub issue
Grub issue
So i was using linux and suddenly power failure occurred. After this insident i can no longer boot to any OS because grub gives me error 17. So i googled a bit and as i understand grub can't read linux disc thats why it gives this error. So my question is: can i somehow make it work without repartitioning linux drives? (btw i fixed windows mbr so that i can go on-line)
- bad_brain
- Site Owner
- Posts: 11636
- Joined: 06 Apr 2005, 16:00
- 19
- Location: In your eye floaters.
- Contact:
you can fix GRUB by using a Linux live CD (Puppy Linux, Damn Small Linux or Knoppix for example, all very small distros and downloaded very fast...but of course every other distro that is using GRUB as boot manager works too):
- boot the CD
- open a shell (or boot into textmode)
you need to know what HDD and what partition Linux is installed now, keep in mind that the count starts at zero, so the first HDD and the first partition is hd0,0....first HDD 2nd partition is hd0,1...2nd HDD first partition is hd1,0 and so on. in my following example I will use the first HDD and the first partition, edit it for your needs!
- ok, now open a shell and type "grub" to enter the GRUB manager, then enter:
then simply reboot and your GRUB menu should appear again as usual...
- boot the CD
- open a shell (or boot into textmode)
you need to know what HDD and what partition Linux is installed now, keep in mind that the count starts at zero, so the first HDD and the first partition is hd0,0....first HDD 2nd partition is hd0,1...2nd HDD first partition is hd1,0 and so on. in my following example I will use the first HDD and the first partition, edit it for your needs!
- ok, now open a shell and type "grub" to enter the GRUB manager, then enter:
Code: Select all
root (hd0,0)
setup (hd0)
exit
Last edited by Macross on 13 Nov 2009, 12:08, edited 1 time in total.
- bad_brain
- Site Owner
- Posts: 11636
- Joined: 06 Apr 2005, 16:00
- 19
- Location: In your eye floaters.
- Contact:
hm, do a filesystem check:
if you are a little lucky fsck will repair it...
Code: Select all
fsck /dev/sdb5
So that means that i can say goodbye to my linux install ?
Code: Select all
fsck.ext2: Attempt to read block from filesystem resulted in short read while trying to open /dev/sdb5
- bad_brain
- Site Owner
- Posts: 11636
- Joined: 06 Apr 2005, 16:00
- 19
- Location: In your eye floaters.
- Contact:
not yet. it is possible the partition table is simply messed up.
run:
this will output the partition table, compare it with the table in /etc/fstab:
if the entries in fstab are different correct them...
run:
Code: Select all
fdisk -p
Code: Select all
cat /etc/fstab