gnu@hoptoad.uucp (John Gilmore) (06/01/89)
A friend has a client who wants him to recover the data from a QIC-24 cartridge tape that was damaged by doing a "tar c" rather than a "tar x". This overwrote the beginning of the tape, but the rest of the data is still out there. The problem is that the tape drive, controller, or software drivers (not sure which) will not let the tape go past the "blank tape" at the end of the new empty tar file. We reproduced the experiment on an Altos 386/2000 running Xenix 5.2, and on a Sun-4 running SunOS 4.0.1 with a Sysgen/Wangtek SCSI tape drive. We wrote a few megs of tar file on the tape, rewound it, and did "tar cf $TAPE" to write a small empty tar file over the data. Neither system would let us read past the first tar file; subsequent dd's just give an error and transfer no data. "mt fsf" spun the tape but didn't have any other effect. "mt status" reports "blank check". My recollection from early Sun days was that the original Archive cartridge drives would let you go past the erased section (giving errors for a while) and then read the old data. Does anyone have a system these days that can do that? If so, whose software and hardware are in it? Such a capability is critical for error recovery in situations like my friend's client's. I'm not surprised that some bozo decided "users are better off if we don't let them do this" but I am surprised that nobody with expensive, inaccessible data sitting a few inches down the tape has made them change it back. -- John Gilmore {sun,pacbell,uunet,pyramid,amdahl}!hoptoad!gnu gnu@toad.com A well-regulated militia, being necessary to the security of a free State, the right of the people to keep and bear arms, shall not be infringed.
buck@siswat.UUCP (A. Lester Buck) (06/04/89)
In article <7488@hoptoad.uucp>, gnu@hoptoad.uucp (John Gilmore) writes: > A friend has a client who wants him to recover the data from a > QIC-24 cartridge tape that was damaged by doing a "tar c" rather > than a "tar x". This overwrote the beginning of the tape, but > the rest of the data is still out there. The problem is that > the tape drive, controller, or software drivers (not sure which) > will not let the tape go past the "blank tape" at the end of > the new empty tar file. [ ... ] > Such a capability is critical for error recovery in situations like my > friend's client's. I'm not surprised that some bozo decided "users are > better off if we don't let them do this" but I am surprised that nobody > with expensive, inaccessible data sitting a few inches down the tape has ^^^^^^^^^^ > made them change it back. If it were only that simple. Short answer, QIC-24 erases 45 inches of tape after the last data written, and that is 45 inches across ALL nine tracks when writing on track 0. Here is an excerpt from the Emulex MT-02 SCSI to QIC-36 manual: To ensure reliable recording operations, when writing on track 0, the MT02 Controller erases ahead of the area on which it is writing. Since the QIC-36 interface tape drive erase mechanism erases all tracks at once, the entire tape has been erased when track 0 has been written. Therefore, data overwrite operations (i.e., writing over an area previously written) are not supported by the MT02. The QIC-24 tape data standard calls for 45 inches of blank tape to follow the last data recorded (the logical end-of- recorded-media). Since writing to track 0 effectively erases the whole tape, this requirement presents no special problems when the MT02 writes to tracks 1 through 8. However, during a write operation to track 0, when the operation completes, 45 inches of blank tape must be erased. A subsequent write operation to track 0 requires that the MT02 reposition the tape back those 45 inches with an associated delay in time. Therefore, the MT02 supports a disable erase ahead option that allows the Initiator to request that the MT02 erase ahead only when the last block written is a file mark or when a REWIND or UNLOAD command is received following a write operation. Using the disable erase ahead option requires a controlled environment in which the user will never remove a tape cartridge without having first issued a REWIND or an UNLOAD command. So without a very special driver that violates the QIC-24 standard at a low level, you should never be able to space past the logical end of media. -- A. Lester Buck ...!texbell!moray!siswat!buck