help with tar on SGI 1/4" tape drive

David Hinds dhinds at elaine20.stanford.edu
Sat Jan 19 08:08:45 AEST 1991


In article <1991Jan18.185120.22578 at odin.corp.sgi.com> olson at anchor.esd.sgi.com (Dave Olson) writes:
>In <1991Jan17.195800.14456 at portia.Stanford.EDU> dhinds at elaine15.stanford.edu (David Hinds) writes:
>| Well, there is a way to get past the EOD, but I'm not sure how much good it
>| will do you.  I did this recently when I accidentally overwrote the header
>| of a 'bru' archive.  I just overwrote the EOD I wanted to get past with a
>| short archive, but ejected the tape before the archive finished.
>
>This is the key.  If you ejected the tape, the tape drive never created
>the EOD indication.  Therefore it simply looks like a bad data block
>(or possibly a media error, depending on how rough you were :) ).
>
>| When I then re-read the tape, 'bru' read my new archive header and the 
>| truncated part of that archive, then registered a hard tape error, and
>| re-synchronized with the original archive I was trying to recover.  I
>| recovered the rest of the tape without any problems.  The reason I don't
>| think this will help you is that 'tar' can't recover from this kind of
>| error in a tape.
>
>Sure it will.  The 'e' option of tar is intended for exactly this kind
>of problem ('corrupted' data on the tape.  However, it won't help for
>the more common case of the original posting, since in that case the
>drive did write the EOD indicator.

Well, yes, but the original poster can easily create my situation the same
way I did, by overwriting his initial mistake but ejecting the tape before
it writes an EOD.  It will just cost him a little bit more of his data,
depending on how quick he is with the drive door.

It might work, but when I tried taking two tar files, spliced them together
in the middle at some random point, and tried reading the spliced file with
tar -e, I couldn't get tar to recover any files past the error.  It did
detect an error in the file, and tried to keep reading, but couldn't
resynchronize with the second tar file.  Maybe it would do better if it hit
a hard error on a tape.  It is worth a try, in any case, unless anyone can
think of a way to read the tape without losing any more data.

 -David Hinds
  dhinds at cb-iris.stanford.edu



More information about the Comp.sys.sgi mailing list