z/OS HCD User's Guide
Previous topic | Next topic | Contents | Index | Contact z/OS | Library | PDF


Batch IODF copy example

z/OS HCD User's Guide
SC34-2669-00

Batch IODF copy example

You may want to use the batch initialize and copy IODF functions when performing system maintenance. For example, these functions can be used when copying all the data sets from one volume (that contains IODFs) to another volume.

The following sample jobs show how to copy multiple IODFs to an alternate volume. In the example it is assumed that the following IODFs exist: SYS1.IODF00 and SYS1.IODF03. The first sample job allocates corresponding data sets on volume DATA02. The second sample job initializes these data sets into IODFs, and copies the source IODFs into the newly created IODFs. Jobs similar to these are contained in member CBDSALIO and CBDSCPIO in SYS1.SAMPLIB.

//* JOB TO DEFINE IODF
//DEFIODF JOB REGION=4M,...
//*
//* DEFINE NEW IODF DATASETS SYS2.IODF00, SYS2.IODF03
//*
//ALLOC    EXEC PGM=IDCAMS
//SYSPRINT DD   SYSOUT=*
//SYSIN    DD   *

     DEFINE CLUSTER (NAME (SYS2.IODF00.CLUSTER) -
                     LINEAR                     -
                     RECORDS (1024)             -
                     VOLUMES(DATA02)            -
                     )                          -
            DATA (NAME (SYS2.IODF00))

     DEFINE CLUSTER (NAME (SYS2.IODF03.CLUSTER) -
                     LINEAR                     -
                     RECORDS (1024)             -
                     VOLUMES(DATA02)            -
                     )                          -
            DATA (NAME (SYS2.IODF03))

//* JOB TO COPY IODF
//INITIODF JOB REGION=4M,...
//*
//* INITIALIZE AND COPY SYS1.IODF00 to SYS2.IODF00
//*
//INIT1    EXEC PGM=CBDMGHCP,PARM='INITIODF SIZE=1024,ACTLOG=NO'
//HCDCNTL  DD *
This IODF is a copy of SYS1.IODF00
/*
//HCDIODFT DD   DSN=SYS2.IODF00,DISP=OLD
//HCDMLOG  DD   SYSOUT=*,DCB=(RECFM=FBA,LRECL=133,BLKSIZE=6650)
//*
//COPY1    EXEC PGM=CBDMGHCP,PARM='COPYIODF'
//HCDIODFS DD   DSN=SYS1.IODF00,DISP=SHR
//HCDIODFT DD   DSN=SYS2.IODF00,DISP=OLD
//HCDMLOG  DD   SYSOUT=*,DCB=(RECFM=FBA,LRECL=133,BLKSIZE=6650)
//*
//* INITIALIZE AND COPY SYS1.IODF03 to SYS2.IODF03
//*
//INIT2    EXEC PGM=CBDMGHCP,PARM='INITIODF SIZE=1024,ACTLOG=NO'
//HCDCNTL  DD *
This IODF is a copy of SYS1.IODF03
/*
//HCDIODFT DD   DSN=SYS2.IODF03,DISP=OLD
//HCDMLOG  DD   SYSOUT=*,DCB=(RECFM=FBA,LRECL=133,BLKSIZE=6650)
//*
//COPY2    EXEC PGM=CBDMGHCP,PARM='COPYIODF'
//HCDIODFS DD   DSN=SYS1.IODF03,DISP=SHR
//HCDIODFT DD   DSN=SYS2.IODF03,DISP=OLD
//HCDMLOG  DD   SYSOUT=*,DCB=(RECFM=FBA,LRECL=133,BLKSIZE=6650)
//
Notes:
  1. This batch job issues job message IEC161I, which can be ignored.
  2. The VSAM DIV file consists of a data and a cluster file. According to the naming convention, the name of the data file is the IODF name (in this example SYS1.IODF01), and .CLUSTER is appended to the data file for a cluster file. Append .CLUSTER to the IODF name in the DEFINE CLUSTER statement (in this example SYS1.IODF01.CLUSTER).

When designating the number of records to be allocated in an IODF (specified on the DEFINE CLUSTER statement and as a PARM value on the INITIODF job step), it is important that the target IODF be allocated at least as big as the source IODF. While using the HCD dialog, you can use the SHOWIODF command from the command line, or the View action bar choice to display the number of records allocated in the source IODF.

Note:
Remember to also copy the associated LOADxx members. For information on the LOADxx members, see z/OS MVS Initialization and Tuning Referencez/OS MVS Initialization and Tuning Reference and z/OS MVS Initialization and Tuning Guidez/OS MVS Initialization and Tuning Guide.

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014