LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 05-22-2007, 01:01 PM   #1
taiwon45753
LQ Newbie
 
Registered: May 2007
Posts: 4

Rep: Reputation: 0
Question Grub Error 17: Pls Help


I am very new to Linux. I recently received the infamous Grub Error 17 at Grub Stage 1.5. I tried booting from the LiveCD Knoppix to find the following in fdisk and the grub menu.lst:

root@Knoppix:/media/hda1# fdisk -l

Disk /dev/hda: 2096 MB, 2096898048 bytes
65 heads, 62 sectors/track, 1016 cylinders
Units = cylinders of 4030 * 512 = 2063360 bytes

Device Boot Start End Blocks Id System
/dev/hda1 1 1016 2047209 16 Hidden FAT16
/dev/hda4 * 1 1 0 0 Empty
Partition 4 has different physical/logical beginnings (non-Linux?):
phys=(0, 0, 0) logical=(0, 0, 1)
Partition 4 has different physical/logical endings:
phys=(0, 0, 0) logical=(1065748, 46, 4)
Partition 4 does not end on cylinder boundary.

Disk /dev/sda: 1021 MB, 1021125120 bytes
255 heads, 63 sectors/track, 124 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/sda1 * 1 96 771088+ 6 FAT16

root@Knoppix:/media/hda1/boot/grub# more menu.lst
default 1
timeout 5
hiddenmenu
root (hd0,0)
title viki
kernel /boot/vmlinuz root=/dev/hda1 rw

root (hd0,0)
title WR_Linux
kernel /boot/bzImage root=/dev/hda1 rw

root (hd0,0)
title WR_Linux NFS
kernel /boot/bzImage root=/dev/nfs rw nfsroot=192.168.8.100:/home/lalabs/
parvus/export ip=192.168.8.1:255.255.255.0:eth0ff
boot

What should I do?
 
Old 05-22-2007, 01:47 PM   #2
pixellany
LQ Veteran
 
Registered: Nov 2005
Location: Annapolis, MD
Distribution: Mint
Posts: 17,809

Rep: Reputation: 743Reputation: 743Reputation: 743Reputation: 743Reputation: 743Reputation: 743Reputation: 743
For starters, what is supposed to be on those two drives?? They are showing as 2GB and 1GB respectively, which seems unlikely.
Also, what were you doing before this happened?

It seems that both partition tables have become corrupted.

Try dumping the partition tables like so--and post the results here:

Code:
dd if=/dev/hda bs=1 skip=446 count=64 | hexdump -C
<Same thing again but with sda instead of hda>>
 
Old 05-22-2007, 07:04 PM   #3
taiwon45753
LQ Newbie
 
Registered: May 2007
Posts: 4

Original Poster
Rep: Reputation: 0
Well, on the hda drive, I had the OS and some files that I was using. The system should be booting from the hard drive. The SDA is merely a 1 GB USB stick that I am using to run the LiveCD.

Just before this whole grub thing was happening I was running this tar file that I got to update some things.

Here is the output of the 'dd' command

root@Knoppix:~# dd if=/dev/hda bs=1 skip=446 count=64 | hexdump -C
64+0 records in
64+0 records out
64 bytes (64 B) copied, 0.00316101 seconds, 20.2 kB/s
00000000 00 01 01 00 16 40 fe f7 3e 00 00 00 d2 79 3e 00 |.....@..>....y>.|
00000010 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|
*
00000030 80 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|
00000040
root@Knoppix:~# dd if=/dev/sda bs=1 skip=446 count=64 | hexdump -C
64+0 records in
64+0 records out
64 bytes (64 B) copied, 0.00168716 seconds, 37.9 kB/s
00000000 80 01 01 00 06 fe 3f 5f 3f 00 00 00 21 88 17 00 |......?_?...!...|
00000010 00 00 01 60 06 fe 3f 7b 60 88 17 00 1c dd 06 00 |...`..?{`.......|
00000020 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|
*
00000040

Thanks for all your help.
 
Old 05-22-2007, 07:58 PM   #4
Junior Hacker
Senior Member
 
Registered: Jan 2005
Location: North America
Distribution: Debian testing Mandriva Ubuntu
Posts: 2,687

Rep: Reputation: 61
According to fdisk -l, you have a fairly old drive with 62 sectors/cylinder (never heard of such a thing). Also, the boot flag is at /dev/hda4 which is "Empty". It also says /dev/hda4 partition is not properly aligned within C.H.S. values, which is not entirely rare. Something upset that partition and the file system is not recognized no more, which is the reason for Error 17, grub does not recognize the "Empty" file system.
I would run testdisk from a Live CD (the USB) to see if it can recover the partition.
 
Old 05-22-2007, 09:29 PM   #5
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,128

Rep: Reputation: 4121Reputation: 4121Reputation: 4121Reputation: 4121Reputation: 4121Reputation: 4121Reputation: 4121Reputation: 4121Reputation: 4121Reputation: 4121Reputation: 4121
I would be guessing somebody opened the MBR in CHS mode - and updated it thus. Win95/98 was bad for doing that.
Testdisk will probably find the (LBA) partitions, but that won't help grub I wouldn't think. You'll need to reset the geometry - could be anyones guess; especially for the cylinder count.
 
Old 05-23-2007, 03:21 PM   #6
taiwon45753
LQ Newbie
 
Registered: May 2007
Posts: 4

Original Poster
Rep: Reputation: 0
I tried running TestDisk from the LiveCD but I got stuck at the partition type. It showed as the choices:

PC/Intel
Apple
Non-Partitioned
XBox
Sun Solaris

I didn't see Linux. Which one should I choose or am I running the wrong testdisk?
 
Old 05-24-2007, 10:36 AM   #7
taiwon45753
LQ Newbie
 
Registered: May 2007
Posts: 4

Original Poster
Rep: Reputation: 0
I tried testdisk with Intel/PC. This is what it showed:


TestDisk 6.5, Data Recovery Utility, October 2006
Christophe GRENIER <grenier@cgsecurity.org>
http://www.cgsecurity.org

Disk /dev/hda - 2096 MB / 1999 MiB - CHS 4063 16 63
Current partition structure:
Partition Start End Size in sectors
test_FAT : Boot sector doesn't have the endmark 0xAA55
1 P FAT16 >32M 0 0 63 4061 15 47 4094418
1 P FAT16 >32M 0 0 63 4061 15 47 4094418

Warning: Bad ending head (CHS and LBA don't match)
No partition is bootable








*=Primary bootable P=Primary L=Logical E=Extended D=Deleted

[Proceed ] [ Backup ]
Try to locate partition
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
ineed help now pls:grub loader lost john_smith Linux - Newbie 11 03-03-2007 03:14 AM
grub option pls explain ravi.ravix Linux - Newbie 2 07-14-2006 02:31 AM
making a grub boot floppy PLS HELP!! mlu Linux - Software 5 09-27-2005 10:25 PM
pls pls pls help me ! i'm tired with httpd config on fedora apache 2.0.48 AngelOfTheDamn Fedora 0 01-24-2004 05:12 PM
dma_intr: error=0x84 (common error, but pls read) devendra112 Linux - Hardware 0 02-06-2003 01:35 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

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

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration