[comp.unix.aux] My Tape Drive Hates Me

MATLEVAN@EKU.BITNET (Jerry LeVan) (10/06/90)

Hello A/UXers,
I sure am having trouble backing up my X11 source disk.

My source disk is a 80 meg apple disk with a single unix
partition ( no mac partition). It is a sysv 5.2 partition.
There is about 70 meg of source and code in the partition
so one tape ( I have the apple 40 meg tape drive) will not
suffice for a backup.

Attempt to do a tar backup results in a write error on the first
write to the second tape ( the output of tar is piped to the tcb
command and thence to the tape device.) I have swapped tapes, cleaned
heads and a run around in circles but I still get a failure as
soon as the second tape is written to. ( Same problem if I attempt
to back up "/").

Cpio evidently does not know about multiple tapes and croaks at
the end of the first tape.

Ok, on to dump.bsd -- heres what basically happens
#/etc/dump.bsd -T5.2 0cf /dev/rmt/tc1 /dev/dsk/c5d0s0
...
DUMP:estimated 67070 tape blocks on 0.87 tape(s).
...
  DUMP:51.09% done,finished in 0:29
  DUMP:tape write error 38848 blocks into tape 1
  DUMP:     tsize=76800, tenths=8, asize=38848
  DUMP:NEEDS ATTENTION:Do you want to restart?: ("yes" or"no")

Three different tapes yielded an identical failure.
Well OK, maybe the "c" option is not setting the parameters
correctly note that it appears to think that only 0.87 tapes will
be used.

I tried the following command to explicitly set the size and
block size.

/etc/dump.bsd -T5.2 0bsf 8k 4800b /dev/rmt/tc1 /dev/dsk/c5d0s0

The above command yielded an identical dialog and failure as
the first command.

ANY help would be appreciated...
(In fact I would like to know if anybody has had any luck
 with the apple tape drive.)
**********************************************************************
I am starting the sixth week of waiting for apple to replace my defective
A/UX 2.0 media (A kind soul at the regional apple office loaded A/UX 2.0
on my disk so I could get "on the air"). Apple keeps sending the stuff back
to my salesman for reasons which sound remarkably like "You were not hopping
on your left foot and spinning in a circle as you mailed the package".

Does Scully accept charges for obscene phone calls?

Jerry
-----------------------------------------------------------------------------
| Jerry LeVan                           | Phone:(606)-622-1931              |
| Department of Computer Science        |                                   |
| Eastern Kentucky University           | Email:matlevan@eku.bitnet         |
| Richmond Ky 40475                     |                                   |
|---------------------------------------------------------------------------|
|      "The series converges so slowly that it actually diverges."          |
-----------------------------------------------------------------------------

rmtodd@servalan.uucp (Richard Todd) (10/07/90)

MATLEVAN@EKU.BITNET (Jerry LeVan) writes:
>#/etc/dump.bsd -T5.2 0cf /dev/rmt/tc1 /dev/dsk/c5d0s0
 Hmm, I should think it would detect the FS type automatically, but it's 
probably best to be paranoid about such things...

>...
>DUMP:estimated 67070 tape blocks on 0.87 tape(s).
>...
>  DUMP:51.09% done,finished in 0:29
>  DUMP:tape write error 38848 blocks into tape 1
>  DUMP:     tsize=76800, tenths=8, asize=38848
>  DUMP:NEEDS ATTENTION:Do you want to restart?: ("yes" or"no")

Yep, this looks like the "c" option isn't quite setting the parameters right. 
"Tape write error" under those conditions, at ~38.8K into the tape, sure 
looks suspiciously like it ran out of tape.  (One "block" according to dump
is 1K; as far as I know nowhere in the docs do they mention this).

   Hmm...an inspired guess: if "tsize" means the size dump thinks your Apple
tape drive has in blocks, then it looks like it's set to about twice as many
blocks as the tape actually has.  This is interesting, because in A/UX 1.1
dump blocks were only half as big (512 bytes).  Anyone want to bet that when
they upped the blocksize on dump they forgot to change the # of blocks that
"c" tells dump accordingly?  

>I tried the following command to explicitly set the size and
>block size.

>/etc/dump.bsd -T5.2 0bsf 8k 4800b /dev/rmt/tc1 /dev/dsk/c5d0s0

  Hmm.  I forgot to mention this in my first reply; as near as I can
tell the option of setting the tape size in terms of number of blocks
instead of number of feet of the (mythical, in the Mac world) 6250bpi
tape doesn't work :-(.  At least, I've never gotten it to work, so I
went back to the system I used on A/UX 1.1 (and is often used on BSD
machines with weird tape drives) i.e. do some creative lying on the
tape length values.

Give this dump command a try; I'm estimating the values here from the ones I
use on my TEAC 150M tape (i.e. multiplying by 38M/150M):

   /etc/dump.bsd -T5.2 0bsdf 8k 532 6250 /dev/rmt/tc1 /dev/dsk/c5d0s0

We're telling it that the tape is a 6250bpi 532-ft tape.  This is a lie, but
it should at least give dump roughly the right idea of how much can fit
on a tape.  Try it a number of times, adjusting the tape length (the "532"
in the above command) until it just fills a tape without going over.
Yes, this is a massive crock, but it does work.   Once you get the tape 
length value right, be sure to write it down or embed it in a shell script to
do your backups for you.  
--
Richard Todd	rmtodd@uokmax.ecn.uoknor.edu  rmtodd@chinet.chi.il.us
	rmtodd@servalan.uucp
"Cancelling a posted message means posting a cancel message."-Maarten Litmaath