Subject: Re: How do I mark bad sectors on my "new" ESDI drives?
To: Tony Reynolds <cctony@tp.backbone.olemiss.edu>
From: Rob Windsor <windsor@ksu.ksu.edu>
List: netbsd-help
Date: 11/01/1994 05:24:11
Verily did Tony Reynolds write:
 
> I've recently recovered a pair of ESDI drives from a very old 386BSD effort. 
> I have a new controller for them, and re-low-level formatted them. They have 
> some bad sectors on them. I would like to know how to use bad144 on them, or 
> failing that, badsect. This is about 450MB worth of disk that I'd rather not 
> see go to waste.
 
> Here's some info:
> netbsd-1.0 from ftp.iastate.edu
> wd0 is a 340MB IDE drive
> wd1 is a 250MB IDE drive
> wd2 is a 313MB ESDI drive (DTC 6280)
> wd3 is a 151MB ESDI drive (DTC 6280)
 
[drive details deleted for brevity...]

> I tried using badsect on wd2, after disklabel, newfs, and fsck. When you 
> follow the procedure in badsect's man page, you get this:
> tp# mount /dev/wd2c /mnt
> tp# cd /mnt
> tp# mkdir BAD
> tp# badsect /mnt/BAD 660416
> /dev/wd2c: Device busy
 
> The same thing happens for wd3c.
 
> (At this point you're supposed to umount/fsck the disk, which will fix the 
> problem if you answer the question correctly at fsck time.)
 
> I grabbed the 386bsd FAQs, and couldn't find anything about badsect or bad144
> with grep.
 
> If this is an FAQ, please point the way. If not, I'll try to collect the 
> responses into one for us.
> (It may also be of limited use, because it's tougher and tougher to buy new 
> ESDI drives these days.)
 
I had similiar "roughage" when trying to install NetBSD-0.9 on my system
early this year.  I've tossed my notes on bad144 since then, so I can't help
you too much there.  (I had to send out "help" mail then also).

A good point of reference is the installation script on the "install-1.0"
diskette.  It will run bad144 if you tell the install script that your
hardware cannot handle bad-sector forwarding (it will ask this if you
specify an ESDI drive).

The problem may be entirely avoided if you can find a way to turn on
hardware bad-sector forwarding on your DTC controller card.

For the Adaptec ESDI cards, it is a -very- subtle "Leave one track for
bad sectors?" question when low-level formatting.  I didn't look for this
message, so I just blew it off and missed it (the first time).

And of course, it's not mentioned in the controller card dox.  8^P

-- Rob
----------------------------------------
Internet: windsor@ksu.ksu.edu      Life: Rob@Manhattan.Kansas.USA.Earth

"Life's a journey, not a destination."  -- Aerosmith (1993), 'Amazing'