Example 11: Recovering using a change accumulation file


This example illustrates the creation and use of change accumulation files in the recovery of a table space. An index on the table in the table space is also rebuilt.

Example 11A: Creating the change accumulation file

The JCL in the following figure creates the change accumulation file.

JCL using R+/CHANGE ACCUM to accumulate log records

//AFREX13A JOB (PAFR),'EXAMPLE 11A',
//         class="Q",NOTIFY=&SYSUID,
//         MSGCLASS=X
//*
//RECOVER EXEC PGM=AFRMAIN,REGION=0M,
//             PARM='DEJM,EXAMPLE11A,NEW/RESTART,MSGLEVEL(2)'
//STEPLIB  DD DISP=SHR,DSN=product.libraries
//          DD DISP=SHR,DSN=DB2.DSNEXIT
//          DD DISP=SHR,DSN=DB2.DSNLOAD
//SYSIN     DD *
 ACCUM GROUP BMCSMPGP
/*
//

Example 11B: Using the change accumulation file

The JCL in the following figure recovers the table space using the change accumulation file created in Example 11A. See Example 11A: Creating the change accumulation file.

JCL recovering a table space using a change accumulation file

//AFREX13B JOB (PAFR),'EXAMPLE 11B',
//         class="Q",NOTIFY=&SYSUID,
//         MSGCLASS=X
/*ROUTE XEQ BMCPLX1
/*JOBPARM SYSAFF=DB2A
//*
//RECOVER EXEC PGM=AFRMAIN,REGION=0M,
//             PARM='DEJM,EXAMPLE11B,NEW/RESTART,MSGLEVEL(2)'
//STEPLIB  DD DISP=SHR,DSN=product.libraries
//          DD DISP=SHR,DSN=DB2.DSNEXIT
//          DD DISP=SHR,DSN=DB2.DSNLOAD
//SYSIN     DD *
 OPTIONS USEACCUM YES
 RECOVER TABLESPACE BMCDBSMP.BMCTS020
 REBUILD INDEX (RDASTC.BMCIX020) NOWORKDDN
/*
//


 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*