The Data Restore APPLYLOG function allows the user to recover the Logical Units of Work (LUWs) contained in the database LISTLOG report. A successful RELOAD RECOVERY=YES and LISTLOG must be performed prior to executing APPLYLOG. The database must be up and running when the APPLYLOG executes.
During the RELOAD RECOVERY=YES function, Data Restore produced work files to record all LUWs found for the tables listed in the RELOAD SYSIN file. These files are kept on the Data Restore machine's 191 disk. If the RELOAD RECOVERY=YES was successful, the LISTLOG function will automatically be executed, and the LISTLOG report sent to the Control Center service machine and the DBA. LISTLOG can also be invoked using Control Center.
Control Center requires that LISTLOG and APPLYLOG can only be executed against the current RELOAD work files.
The LISTLOG identifies all the LUWs recorded in the database log archives and active log for the tables that were listed in the SYSIN file for a RELOAD with RECOVERY=YES.
The LISTLOG function will stop reporting table LUWs when it encounters a DROP statement for any of the affected tables. This includes DROP statements that are used during DBSPACE reorganizations. You will not be allowed to recovery any LUWs after a TABLE DROP statement. Also, if your tables are using referential integrity, the log records will include the original SQL statement plus any cascade response required to maintain referential integrity. During APPLYLOG, all the LUWS will be recreated by the Data Restore product. If referential integrity is active during the APPLYLOG, you may get unexpected results.
APPLYLOG requires that the SYSIN file include the 'END=' command statement to indicate the timestamp for the LUW where the recovery should stop. The LUW referenced in the SYSIN file will NOT be executed. The database administrator will use the LISTLOG report to decide which LUWs need to be re-applied during the APPLYLOG function, and indicate the 'END=' timestamp on the Control Center APPLYLOG panel.
To use APPLYLOG, the DBA will invoke the Control Center APPLYLOG menu interface.
At execution time, the Data Restore machine will perform necessary FILEDEFS and LABELDEFS, create the SYSIN file, and execute the APPLYLOG routine (XTS91001 MODULE). The APPLYLOG SYSPRINT (database APLYLIST) will be sent to the Control Center service machine and the DBA.
The basic files created will be:
No tapes file processing is required. Data Restore will use the database work files found on the Data Restore machine's 191 disk as input.
APPLYLOG requires that the database password for user SQLDBA be included in the 'DBAPW=' SYSIN file control statement.
A password file (drmach LINKPWDS) file is required. Refer to Password File Setup for the Data Restore machine, for instructions on how to implement Data Restore password support.
To invoke APPLYLOG, select Option AL from the Data Restore Menu (Figure 111).
The first entry panel of the APPLYLOG tool is shown in Figure 137.
Figure 137. Data Restore Applylog Utility Menu
+--------------------------------------------------------------------------------+ | mm/dd/yyyy CONTROL CENTER hh:mm:ss | |*----------------------- Data Restore APPLYLOG Utility -----------------------* | || CTRLID: SQMSTDV1 | | || NODE: WMAVM1 | | || Database ==> DB2VM510 DRMACH: SQMREST | | || | | || | | || | | || | | || APPLYLOG END ==> 1998-000-00-00-00-000000 (LUW Timestamp to stop recover | | || | | || Examine the LISTLOG report carefully and note the timestamp desired. | | || | | || Input the timestamp for LUW where APPLYLOG will STOP the recovery. | | || The timestamp you input will NOT be executed. | | || | | || To recover ALL LUWS in the LISTLOG report, input any valid timestamp | | || greater than the last LUW timestamp listed in the LISTLOG report. | | || | | |*---------------------------------------------------------------DRLSTL2-------* | |PF1 HELP PF3 QUIT PF5 View LISTLOG PF10 Execute | +--------------------------------------------------------------------------------+