[comp.sys.sun] Restoring a corrupted tape

adiro@math.tau.ac.il (10/23/89)

   S.O.S.  HELP   S.O.S.  HELP  S.O.S   HELP   S.O.S.  HELP

We have a problem with a corrupted 1/4 inch cartridge that holds important
data. This data was mounted on tape with the help of the unix command "tar
cv". Later we tried to extract this data since this was the only backup we
had for this data. However, instead of typing "tar xv /our/data" we typed
"tar cv /our/data". The tape was not on a write protect status, so the
result was that that last tar command has mounted an empty (since
/our/data did not exist on the file syst the tar puts an "end_of_file"
mark. This means that although our data is still on the tape (the part we
really need is way beyond the start of the tape) we cannot reach it
because the tape drive cannot go beyond the "end_of_file" mark.  We tried
playing with the following commands tar, mt, dd, bru, mtio but with no
success. It might be that we didn't use the correct smart options.  If you
had this problem before or have any idea of what we can do to save this
data please tell us. We are willing to try everything.  We even tried (on
a sample tape) to see if we can physically cut a bad piece from the tape
and connect the two end, but it seems that this action destroys the
structure of the blocks on the tape.

dupuy@cs.columbia.edu (11/08/89)

> We ran into a similar problem on an exabyte tapedrive while developing a
> back-to-back multi-node dump program.  What follows applies to an exabyte
> tapedrive using a Perfect Byte Inc. kernel driver.  It may provide some
> clues as to how to recover your lost data as both exabyte and 1/4" SCSI
> are both screaming tape drives.

[long but detailed and useful description of how to recover a dump omitted]

While the approach you describe is a remarkable technique, there is one
gotcha that may catch anybody trying to restore a 1/4 inch cartridge, as
opposed to an 8mm tape or 1/2 inch reel.

On a 9-track 1/2 inch reel tape, information is recorded in 9 parallel
tracks, from the start of the tape to the end, a byte (plus parity?) at a
time.

On an 8mm cartridge, the infomation is recorded in diagonal stripes, from
the start of the tape to the end, each containing 1024 bytes plus framing
and ECC.

Before data is written, the tape is erased by an erase head located just
before the write head.  Thus, the damage to information is limited to the
part of the tape recorded over, and your approach will work fine.

On a 1/4 inch cartridge, on the other hand, information is recorded bit
serial, on one of 4 or 9 (or more with QIC>24?) serpentine tracks, from
the start of the tape to the end, then back to the start, and so forth.

Before data is written on the first track, *only*, the entire width of the
tape is erased by an erase head located just before the write head.

What this means is that writing information on the first track will also
destroy information on the second, third, etc. tracks.  While you may be
able to write over the LEOT with data, information further on in the tape
will have been destroyed, if there was enough data to fill several tracks.

inet: dupuy@cs.columbia.edu
uucp: ...!rutgers!cs.columbia.edu!dupuy