Corrupted Hard Drive | Unix Linux Forums | Red Hat

  Go Back    


Red Hat Red Hat is the world's leading open source technology solutions provider with offerings including Red Hat Enterprise Linux (RHEL), Fedora, open source applications, security and systems management, virtualization, and Services Oriented Architecture (SOA) solutions.

Corrupted Hard Drive

Red Hat


Closed Thread    
 
Thread Tools Search this Thread Display Modes
    #1  
Old 11-28-2009
2buck56 2buck56 is offline
Registered User
 
Join Date: Nov 2009
Last Activity: 19 November 2012, 11:37 AM EST
Location: Phoenix, AZ
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Corrupted Hard Drive

I am running FC-7 which I realize is an older distro. But my question would apply to any distro.

I ran fsck on my mounted file system (I know, I shouldn't have). Now it won't boot. I get a kernel panic message.

I booted to a Knoppix Live Cd.

The desktop icon shows /dev/sda2 mounted at /media/sda2. When I perform ls -l on /media/sda2 it shows total 0.

When I perform dumpe2fs /dev/sda2 I get this message:
dumpe2fs 1.40-WIP (14-Nov-2006)
dumpe2fs: Bad magic number in super-block while trying to open /dev/sda2
Couldn't find valid filesystem superblock.

Is there any chance of recovering data from the drive or am I out of luck?

fdisk -l yields these results:
root@Knoppix:/ramdisk/home/knoppix# fdisk -l /dev/sda1

Disk /dev/sda1: 106 MB, 106896384 bytes
255 heads, 63 sectors/track, 12 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Disk /dev/sda1 doesn't contain a valid partition table
root@Knoppix:/ramdisk/home/knoppix# fdisk -l /dev/sda2

Disk /dev/sda2: 79.9 GB, 79925045760 bytes
255 heads, 63 sectors/track, 9717 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Disk /dev/sda2 doesn't contain a valid partition table

pvdisplay, vgadisplay, and lvdisplay yields these results:

root@Knoppix:/ramdisk/home/knoppix# pvdisplay
--- Physical volume ---
PV Name /dev/sda2
VG Name VolGroup00
PV Size 74.41 GB / not usable 0
Allocatable yes
PE Size (KByte) 32768
Total PE 2381
Free PE 1
Allocated PE 2380
PV UUID 34v31h-rQS5-Lzjd-WuQC-F1EA-DnE2-Sj1ugr

root@Knoppix:/ramdisk/home/knoppix# vgdisplay
--- Volume group ---
VG Name VolGroup00
System ID
Format lvm2
Metadata Areas 1
Metadata Sequence No 3
VG Access read/write
VG Status resizable
MAX LV 0
Cur LV 2
Open LV 0
Max PV 0
Cur PV 1
Act PV 1
VG Size 74.41 GB
PE Size 32.00 MB
Total PE 2381
Alloc PE / Size 2380 / 74.38 GB
Free PE / Size 1 / 32.00 MB
VG UUID dhzswy-nDmJ-l32M-bTwJ-5tue-Qn1k-Ie9aad

root@Knoppix:/ramdisk/home/knoppix# lvdisplay
--- Logical volume ---
LV Name /dev/VolGroup00/LogVol00
VG Name VolGroup00
LV UUID fhLm4I-YxGM-uPrp-p54E-L0BZ-6RB1-4p9njg
LV Write Access read/write
LV Status NOT available
LV Size 72.44 GB
Current LE 2318
Segments 1
Allocation inherit
Read ahead sectors 0

--- Logical volume ---
LV Name /dev/VolGroup00/LogVol01
VG Name VolGroup00
LV UUID eFHGdu-0lUm-x2qa-vlJD-hayB-20ZT-wbJfYl
LV Write Access read/write
LV Status NOT available
LV Size 1.94 GB
Current LE 62
Segments 1
Allocation inherit
Read ahead sectors 0

Any suggestion or help would be appreciated. Thanks in advance.
Sponsored Links
    #2  
Old 11-28-2009
Corona688 Corona688 is offline Forum Staff  
Mead Rotor
 
Join Date: Aug 2005
Last Activity: 28 November 2014, 11:37 AM EST
Location: Saskatchewan
Posts: 19,944
Thanks: 848
Thanked 3,421 Times in 3,206 Posts
Before we get too carried away, you're using fdisk wrong... sda1 shouldn't contain a partition table. Try fdisk -l /dev/sda.
Sponsored Links
    #3  
Old 11-28-2009
2buck56 2buck56 is offline
Registered User
 
Join Date: Nov 2009
Last Activity: 19 November 2012, 11:37 AM EST
Location: Phoenix, AZ
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Corona688, thanks for the prompt reply. Here is result of fdisk:
root@Knoppix:~# fdisk -l /dev/sda
Disk /dev/sda: 80.0 GB, 80032038912 bytes
255 heads, 63 sectors/track, 9730 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sda1 * 1 13 104391 83 Linux
/dev/sda2 14 9730 78051802+ 8e Linux LVM
root@Knoppix:~#

Also, this is the message I see when trying to boot FC-7:
Uncompressing Linux... OK, booting the kernel
Red Hat nash version 6.0.9 starting
Reading all physical volumes. This may take a while
Found volume group "VolGroup00" using metadata type lvm2
2 logical volume(s) in volume group "VolGroup00" now active
VFS: Can't find ext3 filesystem on dev dm-0
mount: error mounting /dev/root on /sysroot as ext3: Invalid argument
setuproot: moving /dev failed: No such file or directory
setuproot: error mounting /proc: No such file or directory
setuproot: error mounting /sys: No such file or directory
switchroot: mount failed: No such file or directory
Kernel panic - not syncing: Attempted to kill init!

And then the system hangs.

If I interrupt the bootup sequeuence I am able to get to a command
line grub prompt by seleting "e" "a" or "o".
    #4  
Old 12-21-2009
henslewm henslewm is offline
Registered User
 
Join Date: Dec 2009
Last Activity: 7 January 2010, 7:38 PM EST
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Similar Issue...Solution?

Your situation sounds all too familiar unfortunately. Were you able to fix the partition tables and save your data?
Sponsored Links
    #5  
Old 12-21-2009
fpmurphy's Avatar
fpmurphy fpmurphy is offline Forum Staff  
who?
 
Join Date: Dec 2003
Last Activity: 27 November 2014, 11:18 AM EST
Location: /dev/ph
Posts: 4,837
Thanks: 64
Thanked 434 Times in 402 Posts
The kernel panic is due to the nash script interpreter, which is part of initramfs ( switchroot, etc. are nash subcommands), being unable to mount the file systems.

Of more interest is the fact both logical volumes are not available according to the output from lvdisplay

Code:
...
LV Status NOT available
...

If the logical volumes are not available for some reason, then the filesystems on these logical volumes are not available, and thus cannot be mounted.

One possibility is that the LVM metadata is corrupt. LVM maintains the metadata backup in /etc/lvm/backup and /etc/lvm/archive, if you havenít turned off the auto backup feature of LVM. Try restoring the LVM metadata using vgcfgrestore. This should work if the damage to LVM metadata are minor. If the damage to LVM metadata is major, the disk will not be recognized. In such cases, you first need to restore the UUID for the missing device. To do so, compare the output of pvscan and cat /proc/partitions and paste the required UUID using the results of pvscan. You can then use vgcfgrestore to restore LVM metadata. If either of these methods work, make sure to fsck the filesystem(s) before mounting.
Sponsored Links
Closed Thread

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Hard Drive Temperature? ciscocbee Filesystems, Disks and Memory 2 05-27-2008 09:51 PM
Add hard drive to SCO 6.0.0 uxlunatick SCO 13 04-18-2008 10:17 AM
The best partitioning schem for a 250GB Sata hard drive & a 75GB SCSI hard drive sirbijan Filesystems, Disks and Memory 0 04-05-2006 03:19 PM
Trying to copy old hard drive to new hard drive. shorty UNIX for Dummies Questions & Answers 4 01-30-2006 05:47 PM
reading the hard drive victbla UNIX for Advanced & Expert Users 2 01-27-2003 05:03 PM



All times are GMT -4. The time now is 01:58 PM.