eric on 8 Sep 2004 22:55:04 -0000

[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

[PLUG] Hard drive crash - recovery

Fellow Pluggers, I got hammered yesterday morning by the inevitable
hard disk failure :-(

My mail backup is about 6 weeks old, my documents backup is 
similar... but everything else is, apparently, gone.
Based on the error message it appears to be a hardware failure.

Here's my question:  

This is the disk map from fdisk:
# fdisk /dev/hdb

The number of cylinders for this disk is set to 7297.
There is nothing wrong with that, but this is larger than 1024,
and could in certain setups cause problems with:
1) software that runs at boot time (e.g., old versions of LILO)
2) booting and partitioning software from other OSs
   (e.g., DOS FDISK, OS/2 FDISK)

Command (m for help): p

Disk /dev/hdb: 60.0 GB, 60022480896 bytes
255 heads, 63 sectors/track, 7297 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/hdb1   *           1           2       16033+  83  Linux
/dev/hdb2               3          68      530145   82  Linux swap
/dev/hdb3              69        7297    58066942+   f  W95 Ext'd (LBA)
/dev/hdb5              69        7297    58066911   83  Linux

Ive managed to get the data off from the old root partition
(/dev/hdb5) with:
  dd if=/dev/hdb5 of=/data/recovery bs=8k conv=noerror
It had to ignore 7 errors to do that:
The messages were like this but repeated a number of times:
    dd: reading `/dev/hdb5': Input/output error
    2200+0 records in
    2200+0 records out

   cat dd.log |sort -un |grep 'records in'
     2200+0 records in 
     10621+0 records in
     10872+0 records in
     16768+0 records in
     2566020+0 records in
     2568383+0 records in
     3705765+0 records in
     7258311+1 records in  (this is the last record - not an error)

Here's the file that results:
   -rw-r--r--   1 root root 59460090880 Sep  8 12:09 recovery
   (almost 60 Gig file!)

Now, I try to mount the data file as a filesystem:
   mount /home/buffer/recovery /mnt/tmp/ -t reiserfs -o loop=/dev/loop0,ro

but I always end up with this "helpful" message:
mount: wrong fs type, bad option, bad superblock on /dev/loop1,
       or too many mounted file systems
       (could this be the IDE device where you in fact use
       ide-scsi so that sr0 or sda or so is needed?)
I say "helpful" in the sense that it cannot tell the difference 
between "wrong fs type" and, for example, "too many mounted file 
systems" :-P

Before somebody points it out:  Yes, it's a reiserfs.  The error 
messages refered to reiserfs and the same errors happen with ext2fs
or ext3fs.  It was running SuSE 9.0 Professional.

Can anybody point me to some useful sites and/or tools for trying to
recover this?

I tried google but the data recovery companies are so clever that they've
managed to turn every available link that looks informational into an
advertisement for their pay software or service.  I don't mind paying
if I *have to* do so but would prefer to really try something myself
first.  Once I explored the dd and mount options I've reached (some 
would say exceeded) my knowledge limit on data recovery.


# Eric Lucas - temporarily running as
#              until the mess is fixed...
#              one way or the other!
Philadelphia Linux Users Group         --
Announcements -
General Discussion  --