Working with job JCL records for backout
This topic explains how to work with job JCL records, also known as skeleton JCL, to execute recovery for job step backout.
RUV also uses job JCL records to contain skeleton JCL for executing VSAM file backups and restores that are performed by processes that are external to RUV (for external backup support). For more information, see Working-with-job-JCL-records-for-backup-and-restore-processes.
Using the ADD JOB_JCL command
Use the ADD JOB_JCL command to create skeleton JCL, as shown in the following example. Use the JOB_JCL keyword to define the name of the job JCL rule. (This name is the same name you use as the value of the JOB_JCL keyword on an ADD JOB_SET statement.)
ADD JOB_JCL(PROD_BACKOUT);
//<JOBNAME(1,8)> JOB (<ACCOUNT>),CLASS=A,
// MSGCLASS=X,
// REGION=3M
//* PRERECOVERY STEPS AS REQUIRED BY USER
//ZSM0 EXEC PGM=RUVZSM0
<RUV_STEPLIB>
//SYSPRINT DD SYSOUT=*
//SYSIN DD *
<RUV_CONTROL>
<RUV_JOURNAL_DEACTIVATE>
/*
//* POST RECOVERY STEPS AS REQUIRED BY USER
END_DATA;
$$
The ADD_JOB_JCL stores the skeleton JCL in the repository. Use one of the following methods to place the JOB_JCL into the repository:
- Store the recovery JCL in a PDS, and point SYSIN to the PDS member.
- Place the recovery JCL in-stream with other RUV commands, and use the //SYSIN DD DATA,DLM=$$ statement to allow JES to recognize the recovery JCL as input data.
Defining skeleton JCL statements
Skeleton JCL statements are similar to the standard statements you would code for a backout job, except that you can use RUV variables.
At execution, RUV replaces the <RUV_CONTROL> variable with backout control statements that are generated by RUV for the failing program. RUV can submit the generated JCL directly to JES or store the JCL in a PDS. This action is determined by the INTERNAL_READER keyword value of the JOB_RULE statement.
You can include sort parameters in the skeleton JCL. For more information, see Sort-parameters.
In a backout job, you can use the following RUV-defined variables. For more information, see Using-RUV-defined-variables.
- <RUV_JOURNAL_DEACTIVATE>
- <RUV_STEPLIB>
Using the END_DATA keyword
Use the END_DATA keyword to indicate the end of the skeleton JCL.
Coding ADD JOB_JCL statements
To code an ADD JOB_JCL statement, use the following syntax:
{ COMMENT(comment_fields) };
//<JOBNAME(1,8)> JOB (<ACCT>),CLASS=A, ...
//RUVZSM0 EXEC PGM=RUVZSM0
<RUV_STEPLIB>
//SYSPRINT DD SYSOUT=*
//SYSIN DD *
<RUV_CONTROL>
<RUV_JOURNAL_DEACTIVATE>
END_DATA;
Related topic