I wrote a script to copy storagetrek tape drive to a sony tape drive.
The command I used was:
dd if=/dev/rmt/tsp1d1nr of=/dev/rmt/tsp2d1nr bs=262144
How every I didn't set the /dev/rmt/tsp2d1nr tape drive to the 512
(mt -f /dev/rmt/tsp2d1nr setblksz 262144) before starting up the dd
Instead the new sony tapes were formatted by the drive and the block
size defaulted to "variable". I later found out some months later
that the sony tapes were blocked at 16384 (block 32) instead of the
expected 262144 (512 block). I thought that all I had to do was
recopy these tapes and reblock up the tar files back into 512 blocks.
mt -f /dev/rmt/tsp1d1nr setblksz 16384
mt -f /dev/rmt/tsp2d1nr setblksz 262144
dd if=/dev/rmt/tsp1d1nr of=/dev/rmt/tsp2d1nr ibs=16384 obs=262144
4+0 in records
0+0 out records
As you can see it didn't work. I tried all day trying to reblock the
tape to 512 but nothing is working. Does anyone know how to do this
with out untarring the tape to disk and then tar it back to tape?