floppy drive problem

William Palfreman william at palfreman.com
Mon Apr 21 12:04:25 PDT 2003

On Mon, 21 Apr 2003, Chris Pockele wrote:

> Hello,
> I've got a 486 laptop running a FreeBSD 4.7-STABLE snapshot from
> February 4th.  Unfortunately its floppy drive is acting weird under FreeBSD:
> nomad# mount -t msdos /dev/fd0a /mnt
> fd0c: hard error reading fsbn 0 of 0-3 (ST0 40<abnrml> ST1 10<data_overrun> ST2
> 0 cyl 0 hd 0 sec 1)
> msdos: /dev/fd0a: Input/output error

Given the apparent age of the drive, I'd say it was probably faulty.
If you are lucky you just have a faulty floppy disk, and the drive is
ok.  Maybe.

> nomad# dd if=/dev/fd0a /mnt
> dd: unknown operand /mnt

Incorrect use of dd.

> nomad# dd if=/dev/fd0a of=/dev/null
> fd0c: hard error reading fsbn 0 (ST0 40<abnrml> ST1 10<data_overrun> ST2 0 cyl 0
>  hd 0 sec 1)
> dd: /dev/fd0a: Input/output error
> 0+0 records in
> 0+0 records out
> 0 bytes transferred in 7.328928 secs (0 bytes/sec)

Correct use of dd, but the disk or drive still looks faulty.

> When I boot with an OpenBSD boot disk and try the same, it shows
> similar error messages.

Probably a very similar driver.

> This is with various disks which are readable on other machine, and
> even on the same machine under dos/windows, so I presume the drive is
> not broken.

In human years, a 486 is in its early 80s.  Hardware failure for moving
parts is not just a possibility, its a assumption that has to be proved
wrong.  Windows, especially DOS derived versions like 95 or 98, are more
tolerant of faulty hardware than Unixes.  Probably you would find in
use that "Windows seems to screw disks up now and then".  A Unix would
test for more reading and writing faults, and coming across a problem
that windows would miss, would consider the drive to be faulty and
probably refuse to use it.

> There must be some kind of incompatibility between the drive or
> controller and the FreeBSD driver. It works under Linux, although the
> Linux kernel prints some messages about timeouts and unexpected
> interrupts.

Yup, because its faulty.  Linux must just be slightly more failure
tolerant in that respect.  It's noticed the same hardware failure, but
it is prepared to give it a go anyway, complaining.

The main reason for this is only because it uses its own floppy driver
(not a BSD one) that behaves in a slightly different way in cases of
serious error.  It does not imply incompatibility.

> I attached a FreeBSD dmesg (custom kernel - same happens with the
> GENERIC one), and the dmesg from tomsrtbt (a one-floppy Linux
> distribution which loads a ramdisk image from floppy - you can see the
> messages when it starts reading that).
> Does anyone have an idea about how to start debugging or fixing this?

Try with a known good floppy disk, then try cleaning the heads of the
drive unit, or better, stripping the drive down and pulling all the
fluff out too, then try replacing the drive itself, and if you can't
replace it (likely), most of the time move files over the network
(preferably PCMCIA 10Mbit Ethernet, but over parallel or serial TCP/IP
if Ethernet is impossible (broken slot perhaps) if you don't just chuck
it out - and attach the disk to another machine for OS installs, if you
can't go down the bootable CDROM route.  I have seen people use a
converter to attach a laptop IDE disk to a full sized PC controller

W. Palfreman. 			I'm looking for a job. Read my CV at:
Tel: 0771 355 0354		www.palfreman.com/william/cv-wfp2.html

More information about the freebsd-questions mailing list