Port-i386 archive

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

usb connected hard drives and i/o errors.



I'm not sure if this is purely an i386 issue but I'm dealing with
it on a pc and I'm not sure it is generic enough for kern...

The problem is a hard drive that I'm trying to recover data from.

It's a laptop form factor sata drive, so once removed from the
laptop, there are not as many options available... the most obvious
one being to connect it to a USB<->SATA thingy.

This isn't exactly perfect: it appears that this adapter introduces
two failure modes:
- "loud" I/O error (read returns -1)
- "silent" I/O error (read returns as if it read everything but the
 data buffer is unchanged.)

To detect the 2nd, I fill the buffer with a known pattern that is
unlikely to appear on disk and see if the post-read buffer has
the same pattern...not exactly ideal.

I'm looking for recommendations...
- are there USB SATA/IDE connectors that don't silently report errors?
- is there something in NetBSD that is ignoring an error?
- is there a "raw" mode to access hard drives connected via USB in
 such a manner that errors are properly seen by the O/S and where
 the adapter doesn't try to "cover up"?

What really worries me about the silent errors is that I'm sure many
other USB disk enclosures also do this and that I've no way of knowing.

I'm starting to wonder if USB drives are time bombs and if I should have
been doing something else...although I'd be similarly suspicious of firewire.

Darren



Home | Main Index | Thread Index | Old Index