Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 28 Mar 2004 16:25:56 -0700 (MST)
From:      freebsd@wcubed.net
To:        freebsd-questions@freebsd.org
Subject:   hard disk recover
Message-ID:  <3283.24.9.172.8.1080516356.squirrel@webmail.datausa.com>

next in thread | raw e-mail | index | archive | help
I'm getting the dreaded "ad1s1a: hard error reading fsbn 524543 of 96-127
(ad1s1 bn 524543; cn 520 tn 6 sn 5) status=59 error=40" errors.  Based on
what I've read, it means my drive's going bye-bye.  As it is, it won't
even boot - fortunately I have another FBSD drive to boot from, and I get
these errors while trying fsck it.  Shame on me for not noticing the
errors sooner and an even bigger shame for not having a proper backup.

In any case, the milk is spilled and I need to mop it up as best I can. 
While I can mount the partition, I can't cd to it (more "hard errors..."),
and since fsck isn't apparently helping, what can I do to recover what's
left?  I'm thinking dd's the tool to use, but I'm not really sure how to
go about it.  Here's what I get when I try to read from the beginning on
the partition:

# dd if=/dev/ad1s1a bs=64k
dd: /dev/ad1s1a: Input/output error

However, when I add "skip=1", the drive spits back data.  That leads me to
believe that if I skip over the bad sectors, I can read what's left.

I've got a spare drive I can use as a sandbox, but how should I dump the
data?  Should I label the second drive with the same partition size and
"dd if=/dev/ad1s1a of=/dev/ad2s1a"?  Is there any chance of recovering
filesystem data going this route?

Or should I just create a new, empty partition and dump everything from
the bad drive into a huge file and sift through it manually?  This doesn't
appeal to me at all, but there's a few pieces of data on this whose loss
appeals even less.

Help and/or suggestions are most definitely appreciated.

Brad Waite



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3283.24.9.172.8.1080516356.squirrel>