Subject: Copying fits tapes

From: gfl at mail.ast.cam.ac.uk (Geraint Lewis)
Date: 21 Jul 1996 22:04:23 GMT

Hi - I am having serious problems copying a fits tape
 over a network. I have an dat tape, written at ESO, 
 which I need to copy over to an exabyte. The dat drive
 is on a sun (SunOS4.1.3) and the exabyte is on an Alpha
 (OSF/1). lack of disk space does not allow me to copy the
 files off, using iraf, and then back on, so I thought I 
 would use dd - 

 From the sun, I typed:

 dd if=/dev/rst0 bs=2880 files=1000 | ( rsh alpha of=/dev/rmt/0h  ---
 bs=2880 files=1000 )

 The copy appears to work, (ie - blocks in and out agree), but when
 I try and read the exabyte, using iraf under OSF and VMS, as well
 as IDL(vms) the first file is read successfully (ie can be displayed
 etc), but then nothing happens, no prompt is returned, no second file
 is read, everything just sits there. I have tried several dd's now, but 
 this seems to be the outcome.

 Would somebody care to comment on where the possible problem is ?

 Thanks - Geraint

 ps - please feel free to mail me questions on the above, I will put
 together a solution and post it when I have one....

---

From: gfl at mail.ast.cam.ac.uk (Geraint Lewis)
Date: 22 Jul 1996 21:37:04 GMT

In article <4su9h7$qdm at lyra.csx.cam.ac.uk>, gfl at mail.ast.cam.ac.uk (Geraint Lewis) writes:
|> 
     Original message deleted:
|>

 I received a number of responses on my tape copying problem - 
 The problem was to do with EOFs being sent down a pipe, so 
 if files are copied one at a time, they are written, and then
 can be re-read, properly:-

 eg:

 $ set n = 1
 $ while ( $n <= 1000 )
 $   dd if=/dev/nrst0 ibs=2880 | rsh alpha dd of=/dev/nrmt0h obs=2880
 $    at  n++
 $ end

 works a treat: Note that the n in the tape drive name is needed to 
 ensure that it does not rewind between read/writes.

 Many thanks to "Peter G. Ford" <pgf at space.mit.edu> who supplied the above
                 Peter Bunclark <psb at ast.cam.ac.uk>
                 Preben Grosbol <pgrosbol at eso.org>
                 Jim Lewis      <jrl at ast.cam.ac.uk>

 for your help