IAM/PLEX Data Recovery


One of the most important considerations when implementing IAM/PLEX, or any type of data sharing, is how to recover should errors, media failures, or outages occur. The journaling and recovery tools provided with IAM will assist in the recovery of data for the IAM files that are processed under IAM/PLEX. The intent of the information presented in this section is to assist you in planning for your data recovery needs, and to help ensure that appropriate procedures are put in place for the protection of your data.

This section will address performing backout recoveries for failing batch jobs, and forward recoveries from restored IAM data sets. CICS provides the recovery for failed transactions with dynamic transaction backouts, so IAM/PLEX does not provide that capability.

IAM/PLEX Journals

In order to perform recoveries with the IAM tools, you must provide for IAM/PLEX Journaling, as described in IAM-PLEX-parameters. You will need to decide on what type of recoveries you will want to be able to perform. If you want to be able to backout updates from failing job steps, you will need to specify the journaling of before images. If you want to be able to recover files after restoring them from a backup, you will need to be collecting the after images. To provide the best possible recoverability, we recommend that you journal both before and after images. This way, you will be able to perform whatever recoveries may be necessary. To ensure that journaling is being performed for all of your files, it is recommended that you provide the appropriate ACCESS overrides to the IAM/PLEX address space that will specify the level of journaling you need. For example, to specify journaling for all data sets, you can use the following IAM override control card for the IAM/PLEX proc:

ACCESS DD=&ALLDD,JRNAD=BOTH

If you have other override cards, be sure to specify the JRNAD=BOTH on those as well, as the DD=&ALLDD override card is effective only for data sets that are not otherwise explicitly specified on override control cards.

Dynamic Job Backout

IAM/PLEX offers an optional capability to dynamically backout changes made to IAM/PLEX files that were made by an abending job step. The use of Dynamic Job Backout is controlled by the IAM/PLEX parameter DJB, as discussed in IAM-PLEX-parameters. When a job step that has updated IAM files managed by IAM/PLEX abends, if Dynamic Job Backout can be used by that job, then IAM/PLEX will internally schedule the backout. The backout will be performed under the IAM/PLEX instance that the job was directly connected to. Appropriate messages issued upon completion. Upon completion of the backout, IAM/PLEX will release any record locks retained by the failing job step. If the abending job step had taken any IAM syncpoints then the backout will be performed to the last syncpoint taken by the job step. If no syncpoints are found, then all updates made to IAM files managed by IAM/PLEX will be backed out.

Manual Job Backout

If you have not enabled Dynamic Job Backout, and a batch job step abends, you can use IAMJREST to perform a backout of the failing job step. You would not normally want to perform a backout of the updates made by the preceding job steps because those record locks would have been released upon normal step termination, and those records could have subsequently been updated by another batch job or online system. An example of manual job backout is shown below. IAMJREST will automatically release any retained locks upon completion of the backout.

Example of JCL for manual backout (EX2570C)

   //BACKOUT  EXEC    PGM=IAMJREST,REGION=0M
  //SYSPRINT    DD      SYSOUT=*
  //SYSOUT      DD      SYSOUT=*
  //IAMINFO     DD      SYSOUT=*
  //SORTWK01    DD      UNIT=SYSDA,SPACE=(CYL,(50,10))
  //SORTWK02    DD      UNIT=SYSDA,SPACE=(CYL,(50,10))
  //SORTWK03    DD      UNIT=SYSDA,SPACE=(CYL,(50,10))
  //SYSIN      DD      *
       RESTORE BACKOUT,JOBNAME=jobname,STEPNAME=stepname,
     JOBID=JOBnnnnn
  /*

Forward Recovery

A forward recovery may be necessary if an IAM file is damaged due to hardware media failures, or due to software failures. The first step for such a recovery is to restore the IAMdata set from a backup copy. The backup could have been done by an FDRREORG, IDCAMS, or some other application, or it could have been done by a DASD management utility such as FDR or DFSMSdss. Once the data set is restored, you can use IAMJUTIL to reapply all of the updates that had occurred to the data set prior to the failure. For the forward recovery, you would want to specify the FROMDATE and FROMTIME being the time that the backup started, and specify the IAM data set that is being recovered.

In the example below, there is the presumption that the current IAM/PLEX journal log stream has all of the necessary data to perform the recovery, so no journal data sets are specified in the JCL.

Example of a Forward Recovery (EX2070D)

   //RECOVER     EXEC    PGM=IAMJREST,REGION=0M
  //SYSPRINT    DD      SYSOUT=*
  //SYSOUT      DD      SYSOUT=*
  //IAMINFO     DD      SYSOUT=*
  //SORTWK01    DD      UNIT=SYSDA,SPACE=(CYL,(50,10))
  //SORTWK02    DD      UNIT=SYSDA,SPACE=(CYL,(50,10))
  //SORTWK03    DD      UNIT=SYSDA,SPACE=(CYL,(50,10))
  //SYSIN       DD      *
        RESTORE FORWARD,DSN=bad.iam.file,FROMDATE=yyyyddd,
         FROMTIME=hhmmss
  /*


 

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