In this example, a blocked copy on tape is made from an unblocked
sequential disk file. Because the disk data set has a relatively small
block size, the number of buffers explicitly requested is larger than
the default of five. This improves performance by permitting more
overlap of reading the SYSUT1 data set with writing the SYSUT2 data
set.
//COPYJOB JOB
//STEP1 EXEC PGM=IEBGENER,REGION=318K
//SYSPRINT DD SYSOUT=A
//SYSIN DD DUMMY
//SYSUT1 DD DSNAME=INPUT,UNIT=disk,
// DISP=OLD,VOL=SER=X13380,
// DCB=(BUFNO=20,RECFM=F,LRECL=2000,BLKSIZE=2000)
//SYSUT2 DD DSNAME=OUTPUT,UNIT=tape,DISP=(NEW,KEEP),
// DCB=(RECFM=FB,LRECL=2000,BLKSIZE=32000)
The job control statements are as follows:
- The EXEC statement names the IEBGENER program and specifies the
virtual storage region size required. (Calculation of region size
is described in Table 1.)
- The SYSIN DD statement is a dummy, since no editing is to be performed.
- The SYSUT1 DD statement identifies an input disk file. Normally,
the DCB RECFM, LRECL, and BLKSIZE information should not be specified
in the DD statement for an existing disk file because the information
exists in the data set label in the VTOC; it is specified in this
example to illustrate the contrast with the output data set. The unit
and volume serial information could be omitted if the data set were
cataloged. The DCB information specifies BUFNO=20 to allow up to twenty
blocks to be read with each rotation of the disk, assuming the disk
track will hold that many blocks.
- The SYSUT2 DD statement identifies the output tape data set and
specifies a block size of 32,000 bytes. The default of five buffers
should be enough to keep pace with the input.