Data sets that COPYTOCOPY uses
The COPYTOCOPY utility uses a number of data sets during its operation.
The following table describes the data sets that COPYTOCOPY uses. The table lists the DD name that is used to identify the data set, a description of the data set, and an indication of whether it is required. Include statements in your JCL for each required data set and any optional data sets that you want to use.
Data set | Description | Required? |
---|---|---|
SYSIN | Input data set that contains the utility control statement. | Yes |
SYSPRINT | Output data set for messages. | Yes |
Output copies | From one to four output data sets that contain the resulting image copy data sets. Specify their DD names with the COPYDDN and RECOVERYDDN options of the utility control statement. | Yes |
The following objects are named in the utility control statement and do not require DD statements in the JCL:
- Table space or Index space
- Object that is to be copied. (If you want to copy only certain partitions in a partitioned table space, use the DSNUM option in the control statement.)
- Db2 catalog objects
- Objects in the catalog that COPYTOCOPY accesses. The utility records each copy in the Db2 catalog table SYSIBM.SYSCOPY.
- Input image copy data set
- This information is accessed through the Db2 catalog. COPYTOCOPY retains all tape mounts for you. You do not need to code JCL statements to retain tape mounts. If the image copy data sets that are used by COPYTOCOPY reside on the same tape, you do not need to remove the tape.
Output data set size
Image copies are written to sequential non-VSAM data sets.
Alternatively, you can find the approximate size, in bytes, of the image copy data set for a table space by using the following procedure:
- Find the high-allocated page number from the COPYPAGESF column of SYSIBM.SYSCOPY or from information in the VSAM catalog data set.
- Multiply the high-allocated page number by the page size.
Another option is to look at the size of the input image copy.
Cataloging image copies
To catalog your image copy data sets, use the DISP=(NEW,CATLG,CATLG) parameter in the DD statement or TEMPLATE that is named by the COPYDDN or RECOVERYDDN option. After the image copy is taken, the DSVOLSER column of the row that is inserted into SYSIBM.SYSCOPY contains blanks.
Duplicate image copy data sets are not allowed. If a cataloged data set is already recorded in SYSIBM.SYSCOPY with the same name as the new image copy data set, a message is issued and the copy is not made.
When RECOVER locates the entry in SYSIBM.SYSCOPY, it uses the ICF catalog to allocate the required data set. If you have uncataloged the data set, the allocation fails. In that case, the recovery can still go forward; RECOVER searches for a previous image copy. But even if RECOVER finds one, it must use correspondingly more of the log to recover. You are responsible for keeping the z/OS® catalog consistent with SYSIBM.SYSCOPY with regard to existing image copy data sets.