7.2 AWSUTIL (AWS format tape file generation utility)

AWSUTIL is written by Brandon Hill and is available on the CBT MVS Utilities Tape (CBTTAPE) at

www.cbttape.org (File #477).

7.2.1 Function

AWSUTIL is a comprehensive program for creating AWS format virtual tape files. The program can gene-
rate labels and write tape marks. Any dataset that can be accessed by BSAM can be copied to a virtual
tape file. Any real tape device can have either a single file or the entire tape copied.

The commands for the utility are read from the SYSIN DD statement and status and errors are written to
the SYSPRINT DD statement. The AWS tape image is written to SYSOUT as a VB file. This file is then
suitable to be copied with FTP in binary mode to any other system.

Any number of DD statements representing sequential data and tapes can be specified and are read via
the appropriate statement in SYSIN.

7.2.2 Control Statements

AWSUTIL supports these SYSIN control statements:

READ ddname

Perform BSAM read from ddname and convert each block to AWS tape format.
This works on whatever BSAM will read. The maximum BLKSIZE is 32760.

GET ddname

Perform QSAM read from ddname and convert each block to AWS tape for-
mat. This works on whatever QBSAM will read. The maximum BLKSIZE is
32760.

TAPEFILE ddname

Perform EXCP read from a real tape device and convert each block to AWS
TAPE format. Only works on a tape device. Maximum BLKSIZE is 65535. This
command stops reading when a tape mark is read. Therefore only the current
tape file is processed. If BLP were used only the tape headers would be
processed.

TAPEALL ddname

Perform EXCP read from a real tape device and convert each block to AWS
TAPE format. Only works on a tape device. Maximum BLKSIZE is 65535. This
command rewinds the tape and reads until an error condition is returned. This
effectively copies the entire contents of the tape. BLP is not necessary as a re-
wind command is sent before the tape is read. Tape marks are duplicated as
they are encountered.

NOTE: Because end of reel reflectors are rarely effecttive this command can
run a tape off the reel on a 3420 type drive. 3480 / 3490 / 3590 type drives
have better stopping mechanisms.

TAPEMARK

Write a tape mark to the output file. This is usually used to separate individual
files on a tape. Two consecutive tape marks sometimes signals the end of the
tape.

VERIFY

Print a message after each command verifying that the command was exe-
cuted ok. This merely prints a message. It has no effect on the integrity of the
data. Because SYSOUT should be directed to disk there should be no data
integrity problems anyway.

ASCII

All subsequent labels generated are converted to ASCII before they are wri-
tten. This only affects labels. All data is copied exactly as it is read no matter
the setting of this command.

EBCDIC

All subsequent labels generated are not to be converted before they are wri-
tten. The implication is that the data is still in EBCDIC format. This only affects
labels. All data is copied exactly as it is read no matter the setting of this com-
mand.

VOL1

These commands write 80 byte labels to the tape image. The format of the
labels is controlled by the ASCII and EBCDIC commands. Except for the first 4
bytes of each input line none of the data is checked to make sure it is a valid
tape label. It is up to the user to provide correctly formatted labels as desired.
Essentially the entire 80 byte input record is written to the AWS TAPE image
as is (or converted to ASCII if this flag is set).

HDR1 - HDR2

See VOL1 above.

EOF1 - EOF2

See VOL1 above.

EOV1 - EOV2

See VOL1 above.

UHL1 - UHL8

See VOL1 above.

UTL1 - UTL8

See VOL1 above.

7.2.3 Examples

The following example reads the first dataset from DASD and a second one dataset from tape and writes
them to an AWS format dataset.

//MAKETAPE EXEC PGM=AWSUTIL

//STEPLIB DD DISP=SHR,DSN=my.load.library

//SYSPRINT DD SYSOUT=*

//SYSOUT DD DISP=(,CATLG),SPACE=(TRK,(15,15)),DSN=my.dsname

//INDATA DD DISP=SHR,DSN=my.input.sequential.data

//INTAPE DD DISP=OLD,DNS=my.real.tape.file

//SYSIN DD *

READ INDATA

TAPEMARK

TAPEFILE INTAPE

TAPEMARK

/*

Figure 63: AWSUTIL utility JCL

Previous Page Next Page