*BSD News Article 65572


Return to BSD News archive

Path: euryale.cc.adfa.oz.au!newshost.anu.edu.au!harbinger.cc.monash.edu.au!news.rmit.EDU.AU!news.unimelb.EDU.AU!munnari.OZ.AU!news.ecn.uoknor.edu!paladin.american.edu!gatech!newsfeed.internetmci.com!in1.uu.net!brighton.openmarket.com!decwrl!tribune.usask.ca!rover.ucs.ualberta.ca!news.ucalgary.ca!news
From: gord@enci.ucalgary.ca (Gord Matzigkeit)
Newsgroups: comp.unix.bsd.freebsd.misc
Subject: HELP: Recovering from hard disk failure...
Date: 09 Apr 1996 11:28:30 -0600
Organization: Civil Engineering, University of Calgary
Lines: 73
Sender: gord@enci.ucalgary.ca
Message-ID: <np3f6d5mtd.fsf@enci.ucalgary.ca>
Reply-To: Gord Matzigkeit <gord@enci.ucalgary.ca>
NNTP-Posting-Host: @casual1.enci.ucalgary.ca
Mime-Version: 1.0 (generated by tm-edit 7.41)
Content-Type: text/plain; charset=US-ASCII
X-Attribution:  Gord
X-Newsreader: Gnus v5.0.15

Hello, all!

I've been a satisfied user of FreeBSD 2.1.0-RELEASE for as long as
I've owned a computer.  Recently, I upgraded hardware (moved to an
i486/66, with 10MB RAM), and ran into a few problems.

The worst was that my hard disk finally bit the dust.  I was merrily
compiling GCC on the console (with Objective C support so that I can
try GNUSTEP), when the screen suddenly filled with bright white kernel
messages (I suspect they were the same as the ones below), and the
system reset.

Then the BIOS didn't recognize my Maxtor 814MB IDE drive at bootstrap.
Ouch.

Turning off the machine and trying again got me back into FreeBSD,
where I was dropped to single-user mode because `fsck -p' failed.

I ran fsck manually, and corrected a lot of problems (some
non-critical files in /usr/sbin were corrupt and had to be removed).
Then, while scanning /usr, fsck tickled the following:

...
wd0e: hard error reading fsbn 69 of 64-175 (wd0 bn 163909; cn 162 tn 9
sn 46)wd0: status 59<seekdone,drq,err> error 40<uncorr>

CANNOT READ: BLK 64
CONTINUE? [yn] y

wd0e: hard error reading fsbn 69 (wd0 bn 163909; cn 162 tn 9 sn
46)wd0: status 59<seekdone,drq,err> error 40<uncorr>
THE FOLLOWING DISK SECTORS COULD NOT BE READ: 69,
...

Or something like that.

So, what can I do?  I really, really want to mount my /usr partition,
so that I can recover what I was working on.  But, FreeBSD won't let
me use it after I mount... it keeps making a grinding noise (retry, I
presume), and `ls', or whatever other program I ran, exits with "I/O
error".

Am I royally screwed?  What is the best way for me to recover as much
as I can, right away?  If FreeBSD is able to cope with the bad block
(how???), then I would try to recover as much as I can, and plop it on
a new disk right away.

I would even (if FreeBSD can't cope) hand-salvage the disk with a hex
dumper, but I'm not familiar with how to do that under *BSD or Linux,
and all my antique MS-DOG tools (like Norton disk commander) can't
even read the raw partition.

The MS-DOG part of the disk isn't owned by me... fortunately it isn't
affected, or I'd be in really deep doodoo.  I have the BIOS geometry
set so that MS-DOG can only access (and inhabit) the first 280MB of
the disk.  I suspect that changing the geometry info would be A Very
Bad Thing(tm).

I'd really appreciate a kind answer... hopefully a way to have FreeBSD
just mark the block as bad so that I can get on with my life.

PS.  I have a spare 120 MB UFS partition on wd0f (that I'm currently
using to run the GNU Hurd), that would be available if I need to get a
fully-working /usr again without using wd0e.  I also have all the
FreeBSD tarballs kicking around on the DOG slice.  So, there is a
little leeway if the solution to my problem requires breathing room.

--Gord

-- 
   Gord Matzigkeit    | Jaques Cousteau loved programming in assembler.
gord@enci.ucalgary.ca |[This line is for sale.  Contact me for details.]