mt bsf with sequential dumps to Exabyte
Stuart Levy
slevy at poincare.geom.umn.edu
Mon Dec 31 06:45:31 AEST 1990
Appending to Exabyte tapes is a pain with the Sun 4.1 driver, but
possible. You have to accomplish the following:
- position the tape immediately PRECEDING an EOF mark
(preferably the one following the last useful data on the tape :->)
- [re]write that EOF
After this it's safe to write data, possibly multiple files, until you
reposition the tape (rewind, skip files &c.). Supposing there were <N>
data files already on the tape, with the last one followed by a double
EOF, normal UNIX tape drivers would perform the above sequence with
mt rew
mt fsf <N> # Skip past last filemark, between double EOFs
mt bsf 1 # Position after last data, before double EOF
mt weof # Rewrite EOF
However, Sun's tape driver is brain-damaged and does not allow this; it
doesn't have the idea of the beginning-of-tape side of a file mark. But
you can get the desired effect with
mt rew
mt fsf <N-1> # Skip to BEGINNING of last file
dd if=/dev/nrst0 bs=63k of=/dev/null
# Read last file's data
# The tape is now positioned after last data
mt weof # Rewrite EOF
This seems to work at least with the Sun 4.1 SCSI driver.
The above owes much to George Goble of Purdue, who wrote a fine
explanation of the Exabyte's workings and the Sun SCSI tape driver's
peculiarities; it appeared in Sun-spots around the turn of 1988-89 I
think.
[Ed's Note: The articles are in v7n46 and v7n68, circa Dec 1988. -bdg]]
Stuart Levy, Geometry Group, University of Minnesota
slevy at geom.umn.edu
More information about the Comp.sys.sun
mailing list