[ncr.sys.unix] Copying from one tape to another tape

steve@pmday_2.Dayton.NCR.COM (Steve Bridges) (01/11/90)

My co-workers and myself are trying to figure something out.  The situation
is, suppose, I have a tape in cpio format, and want to copy it to another
tape (separate drive) using cpio without putting a temporary copy on disk.

A possible scenario follows:  I have a 150mb tape with some files somebody
with another tower wants.  They only have a 45mb tape drive, but I have
both a 150mb and a 45mb tape drive.  I want to copy what is on
the 150mb tape to a 45mb tape without putting a copy in disk.

So far, I have tried:

cpio -idmuvcB < /dev/rtp | cpio -ocvB > /dev/rtp1

It worked, but put a copy of all the files on disk.

I tried cpio -ocvB < `cpio -idmuvcB < /dev/rtp` > /dev/rtp1
but it didn't work

Would  cpio -idmuvcB < /dev/rtp > cpio -ocvB > /dev/rtp1
do what I want without putting a copy on disk?

Thanks in advance for any responses.




-- 
Steve Bridges                    | NCR - USDPG Product Marketing and Support OLS
Steve.Bridges@Dayton.NCR.COM     | Phone:(513)-445-4182 622-4182 (Voice Plus)
..!ncrlnk!usglnk!pmday_2!steve   | AOPA #916233
..!uunet!ncrlnk!usglnk!pmday_2!steve| PP-ASEL, AMEL

stevem@sauron.Columbia.NCR.COM (Steve McClure) (01/11/90)

In article <812@pmday_2.Dayton.NCR.COM> steve@pmday_2.Dayton.NCR.COM (Steve Bridges) writes:
|A possible scenario follows:  I have a 150mb tape with some files somebody
|with another tower wants.  They only have a 45mb tape drive, but I have
|both a 150mb and a 45mb tape drive.  I want to copy what is on
|the 150mb tape to a 45mb tape without putting a copy in disk.
|
|Thanks in advance for any responses.

Steve, what about dd if=/dev/150Mtape of=/dev/45Mtape bs=100k    ???

Steve McClure
-----
stevem@Columbia.NCR.COM
The above are my opinions, which NCR doesn't really care about anyway!
CAUSER's Amiga BBS! | 803-796-3127 | 8pm-8am 8n1 | 300/1200/2400

wescott@Columbia.NCR.COM (Mike Wescott) (01/14/90)

In article <812@pmday_2.Dayton.NCR.COM> steve@pmday_2.Dayton.NCR.COM (Steve Bridges) writes:
> cpio -idmuvcB < /dev/rtp | cpio -ocvB > /dev/rtp1

What this command line says is "read /dev/rtp and let cpio dearchive (put on
disk) all the files it finds there spitting out the file names as it goes.
The second cpio reads those file names and recreates the archive on /dev/rtp1.

> Would  cpio -idmuvcB < /dev/rtp > cpio -ocvB > /dev/rtp1
> do what I want without putting a copy on disk?

Nope. Not even valid syntax.  You can't redirect stdout twice on the same
command.  The command that the shell parses out looks just the same as:

	cpio -idmuvcB -ocvB < /dev/rtp > cpio > /dev/rtp1

Your best bet is plain old dd(1):

	dd if=/dev/rtp of=/dev/rtp1 bs=100k

should do the trick with reasonable efficiency.
--
	-Mike Wescott
	 mike.wescott@ncrcae.Columbia.NCR.COM