* reading a tape with several diff block sizes @ 1997-02-20 5:00 Robin S Levine 1997-02-20 5:00 ` christopher f. chiesa 1997-02-20 5:00 ` James Kirkpatrick 0 siblings, 2 replies; 4+ messages in thread From: Robin S Levine @ 1997-02-20 5:00 UTC (permalink / raw) Have kinda of a strange one. Need to read a tape that has several files on it, that are all blocked differently and have different blocksizes. Really have no desire to read it one char at a time (too long). Would like to know if there is a way to mount a tape multiple times with diff blocksizes without rewinding it or any other suggestions you may have ? Much Thanx in advance Robin S Levine Information America / Atlanta, GA ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: reading a tape with several diff block sizes 1997-02-20 5:00 reading a tape with several diff block sizes Robin S Levine @ 1997-02-20 5:00 ` christopher f. chiesa 1997-02-20 5:00 ` James Kirkpatrick 1 sibling, 0 replies; 4+ messages in thread From: christopher f. chiesa @ 1997-02-20 5:00 UTC (permalink / raw) In article <01bc1ecd$1c3510e0$702835cf@robinkaryn>, Robin S Levine <rlevine@bellsouth.net> wrote: > >Need to read a tape that has several files on it, that are all blocked >differently and have >different blocksizes. Really have no desire to read it one char at a time >(too long). > >Would like to know if there is a way to mount a tape multiple times with >diff blocksizes >without rewinding it or any other suggestions you may have ? If I correctly understand what you want to do, there's no need to remount it at all. I read tapes with variable blocksizes all the time, with just one Mount. The one "gotcha" is this: you have to use MOUNT/FOREIGN, and if the files are ANSI you have to process the ANSI formatting YOURSELF. That being said, I would write a program that $ASSIGNed a channel to the tape drive and used $QIOW to read the tape in a block-by-block manner. Each $QIOW would request the "largest possible" blocksize -- 65535 bytes as of VAX/VMS V5.4-3; has the limit perhaps been upped in more recent VMS versions? -- and would look at the "byte transfer count" field of the associated I/O Status Block upon completion of the operation, to FIND OUT how many bytes, i.e. what size block, was ACTUALLY OBTAINED. Jacket this in whatever ANSI-format-interpretation logic you deem necessary, and VOILA -- no more problem. I've actually written a program like this, to recover ANSI-format files from a tape whose first half had gotten overwritten by a BACKUP saveset; that probably wasn't strictly necessary but I didn't know any better methods at the time. I'd offer you the program, but it is highly customized for the one particular tape I was working on, and moreover is written in Macro-32 assembly which most people don't seem to know... If none of this deters you, e-mail me for a copy. All in all, if you're not comfortable with system-service programming or the use of $QIOW in particular, this may be the "long way around the tree" for you, and you may be better off just biting the bullet and doing a DISMOUNT-and-reMOUNT sequence for each file... That may make it take longer (possibly MUCH longer, particularly if you're using a tape medium (e.g. 8mm Exabyte) that takes painfully long to do "repositioning") to read the tape, but may be more within your capabilities if you're a non- programmer. On the other hand, if you have many tapes to do, it might be worth the effort to write a program, or have someone else write one for you (e-mail me for info on THAT, too, if that's of interest ;-)). Hope this helps. You're welcome in advance! Chris Chiesa lvt-cfc@servtech.com ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: reading a tape with several diff block sizes 1997-02-20 5:00 reading a tape with several diff block sizes Robin S Levine 1997-02-20 5:00 ` christopher f. chiesa @ 1997-02-20 5:00 ` James Kirkpatrick 1997-02-20 5:00 ` Paul Edgington 1 sibling, 1 reply; 4+ messages in thread From: James Kirkpatrick @ 1997-02-20 5:00 UTC (permalink / raw) In article <01bc1ecd$1c3510e0$702835cf@robinkaryn>, "Robin S Levine " <rlevine@bellsouth.net> writes: |>Have kinda of a strange one. |> |>Need to read a tape that has several files on it, that are all blocked |>differently and have |>different blocksizes. Really have no desire to read it one char at a time |>(too long). |> |>Would like to know if there is a way to mount a tape multiple times with |>diff blocksizes... One big difference here might be whether it's labeled or not. You didn't really give us much information to go on. In this kind of a situation I usually just write a program to do this. Use $QIO to read the tape into a very large (64K byte) buffer, and let the system service tell me how big the block actually was, and deblock from there. Of course I'm one of those ancient fossils that actually can write programs instead of re-install Win95 applications each time they act funny. (OK, so I'm grumpy this morning :-) ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: reading a tape with several diff block sizes 1997-02-20 5:00 ` James Kirkpatrick @ 1997-02-20 5:00 ` Paul Edgington 0 siblings, 0 replies; 4+ messages in thread From: Paul Edgington @ 1997-02-20 5:00 UTC (permalink / raw) In article <1997Feb20.082621.26254@roper.uwyo.edu>, jimkirk@uwyo.edu (James Kirkpatrick) writes: > >In article <01bc1ecd$1c3510e0$702835cf@robinkaryn>, "Robin S Levine " <rlevine@bellsouth.net> writes: >|>Have kinda of a strange one. >|> >|>Need to read a tape that has several files on it, that are all blocked >|>differently and have >|>different blocksizes. Really have no desire to read it one char at a time >|>(too long). >|> >|>Would like to know if there is a way to mount a tape multiple times with >|>diff blocksizes... > >One big difference here might be whether it's labeled or not. You didn't >really give us much information to go on. > I need to do exactly the same with an old tape a little while back. Look for a utility called ETAPE in the decus software archive. Paul -- Paul Edgington, VMS, WWW & IPA | What to do if you ever find yourself on the same helicopter as Fergy... http://www.ccdc.cam.ac.uk/bungy.html Cambridge Crystallographic Data Centre, 12 Union Rd, Cambridge, CB2 1EZ. Em: pre10.wibble@chemcrys.cam.ac.uk | <-- remove wibble for real address ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~1997-02-20 5:00 UTC | newest] Thread overview: 4+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 1997-02-20 5:00 reading a tape with several diff block sizes Robin S Levine 1997-02-20 5:00 ` christopher f. chiesa 1997-02-20 5:00 ` James Kirkpatrick 1997-02-20 5:00 ` Paul Edgington
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox