Proper method of tarring to a pipe, without ``blocksize=1'' later?

Arthur Evans arthur at sgi.com
Wed Apr 3 04:13:42 AEST 1991


In article <5909 at tahoe.unr.edu> malc at equinox.unr.edu (Malcolm Carlock) writes:
>When using a command of the form
>
>	tar cf - file ... | rsh somewhere dd of=/dev/rmt0
>
>Is there a way of getting the remote dd to write the tape such that
>the blocksize of the final tar image on tape is something other than 1?

I think you're asking the wrong question.  I suspect
that tar is writing a with a blocksize of 1, since
it's writing to standard output.  Try using the 'b'
option to tar to specify a blocking factor.  Read your
tar man page under the 'b' option.  Mine says:

"Due to the blocking algorithm, a tar tape created by writing
to the standard output should be read from standard input."

So you may need to read the tape with "tar xf - < /dev/rmt0"
or even (ich) "dd if=/dev/rmt0 | tar xf -".

As always, your milage may vary.  Good luck.

-arthur

--
Arthur Evans -- Information Decorator, Akbar and Jeff's Documentation Hut



More information about the Comp.unix.questions mailing list