Disaster Recovery

Lack of availability may affect your operations, income and reputation. It is difficult to be prepared for every possible recovery scenario. There are too many. The DBA must have good skills and tools to help him generate recovery jobs easily and quickly for each specific scenario.

Mass Recovery
Disaster recovery scenarios may create the need to recover a high number of objects. The recommendation is to recover many objects in a single recover statement to allow Db2 to pass the log records once for all included objects. Multiple log reads can significantly slow down recovery, especially if the log records are no longer available in the active logs and archive logs must be accessed. It is a good practice to generate the recover jobs and have them available in a library so you do not have to spend too much time in kick starting the recover process. In addition, it is a good idea to set higher priorities for your most critical databases, to allow you to resume business activity as soon as your strategic applications become available.

Ensuring Recoverability
The QUIESCE utility is often used to set a point of consistency for recovery. However, QUIESCE does not ensure recoverability because you cannot recover if the last full image copy is lost, logs are lost or a non recoverable event occurred since the last backup. To ensure that points of consistency are recoverable, you need to look for non recoverable events. A non recoverable event is any event manipulating the data without recording the changes in the Db2 log. This can happen with Db2 utilities running with the LOG NO option such as REORG, LOAD and CHECK. It is a good idea to take an image copy after running these utilities or before QUIESCE. If the changes are not logged, the RECOVER utility cannot recover the data to current or to a point in time after the event.

The availability of the image copy datasets is also critical. Image copies can be deleted accidently or when expired. Image copies are also required for new populated tables that have not been copied yet. Recovery fails if the image copy datasets were deleted and are no longer available. It is a good practice to check for the availability of the last full image copy prior to QUIESCE and take a new image copy if the last copy is missing.

Recovering Indexes
If you recover to a point in time, you must also rebuild the associated indexes. Rebuilding large indexes could delay availability. It is recommended to backup large indexes, because recovering indexes with backups can significantly speed up the recovery process.