Using REALDD
You can also optionally allocate the tape unit with a DD statement in the JCL. You might want to do this, for example, to ensure the availability of a tape unit.
To stack copies on tape
- Specify STACK YES in an OUTPUT statement.
Specify the following option in the same OUTPUT statement to allocate the tape unit with a DD statement (which forces allocation at step initiation).
STACK YES REALDD DDNameIn this statement, DDName is a DD statement such as TAPEDD in the following example:
//TAPEDD DD DSN=DYNAMIC,
// DISP=(NEW,KEEP,KEEP),
// DCB=SYS1.MODEL1,UNIT=CART,
// VOL=(,,,20),RETPD=30When using REALDD with grouping and multitasking and a DDName not greater than 6 characters, the REALDD DDName can act as a prefix and is suffixed with the 2-digit task number to create a composite DDName. If the DDName is not found, BMC AMI Copy then looks for the composite name and substitutes it for the original REALDD DDName. This allows you to spread REALDD outputs across multiple tape units. For example, if you specify REALDD TAPEDD and MAXTASKS (3,3), BMC AMI Copy looks for TAPEDD01, TAPEDD02, and TAPEDD03 if TAPEDD is not found. Task 1 will use TAPEDD01, task 2 will use TAPEDD02, and task 3 will use TAPEDD03. The BMC AMI Copy commands would be similar to those below:
OPTIONS MAXTASKS (3,3)
OUTPUT TAPEOUT UNIT TAPE STACK YES REALDD TAPEDDThe JCL for this example would contain the following lines:
//TAPEDD01 DD UNIT=CART, ...
//TAPEDD02 DD UNIT=CART, ...
//TAPEDD03 DD UNIT=CART, ...When you use REALDD and provide a DD statement, note the following items:
- Dynamic allocation of the tape drive does not occur, and the DD statement takes precedence over all output descriptor options except DSNAME, COPYDSN, RECOVERYDSN, and CATLG.
- You must provide an adequate volume count in your DD statement. The MVS system default volume count is 5.
- You must provide a DSN value, otherwise a work tape will be mounted and not retained.
- You must use DISP=(NEW,KEEP,KEEP). Do not specify CATLG in the DISP field, otherwise you might receive a NOT CATLG 2 message.
- You must not use the same REALDD for two different subtasks at the same time.
- You must not associate the same REALDD DDName to more than one output descriptor.
- When using STACK YES, you must not reference the same DD statement from two different OUTPUT descriptors.
- When you specify STACK YES and a value for REALDD, REALDD is always used.