Read FCOPY tape with DD in HPUX (183 Views)
Reply
Occasional Visitor
Ron Angel_1
Posts: 1
Registered: ‎06-10-2004
Message 1 of 2 (183 Views)

Read FCOPY tape with DD in HPUX

I have some database files written to tape with FCOPY using a fixed record length. I'm only able to get every tenth record from the tape to a file using dd.
Trusted Contributor
Lars Appel
Posts: 131
Registered: ‎12-27-1996
Message 2 of 2 (183 Views)

Re: Read FCOPY tape with DD in HPUX

Ron,

depending on the blocking factor that the tape has been written with, you might need to use the dd options cbs=n and conv=unblock to get the lines split on the unix side...

For example, if you create a tape with rec size 80 bytes and block factor of 10, the physical tape records contain 800 bytes each. So you would split them with dd like this...

:file t ;dev=tape ;rec=-80,10,f,ascii
:fcopy from=myfile ;to=*t

$dd if=/dev/tape of=myfile ibs=800 obs=80 cbs=80 conv=unblock

The above is from memory, I don't have a unix system at hand to try. However, it might get you into the right direction ;-)

Lars.
see www.google.com/search?q=lars+appel
The opinions expressed above are the personal opinions of the authors, not of HP. By using this site, you accept the Terms of Use and Rules of Participation.