Purge time for database recovery and Database Change Accumulation utility

A purge time is the timestamp DBRC uses to start collecting changes for a database or area that might need to be recovered using either an image copy or a HALDB Online Reorganization as a starting point for a recovery. Changes prior to this timestamp are purged from change accumulation data sets and are not considered for database recovery.

Image copy purge times

If updates are not occurring (no active allocation records in RECON for the database), the run time of the image copy is used as the purge time. If updates are occurring when an image copy is run, DBRC checks checkpoint timestamps on logs previous to the run time of the image copy. For full function databases (including HALDBs), only one checkpoint on a previous log is considered. For Fast Path databases, two checkpoints on previous logs are considered. In order to keep purge times moving forward in time, ensure checkpoints exist on each log for each IMS updating the database.

The run time of the image copy is selected as the purge time for the following types of image copies for both full function and Fast Path databases:

  • Database Image Copy (DFSUDMP0) utility was used to create the image copy while the database was unavailable for update (BATCH).
  • Database Image Copy 2 utility invoked DFSMS Fast Replication to take an image copy while the database was unavailable for update processing (SMSOFFLC).
  • Database Image Copy 2 was used to create the image copy while the database was unavailable for update processing (SMSNOCIC).
  • Online Database Image Copy utility was used to create the image copy (ONLINE).

For other types of fuzzy image copies, DBRC uses an earlier checkpoint ID to ensure that all the changes are included for the Database Recovery or the Database Change Accumulation utility, as long as the database is allocated when the fuzzy image copy is run. If the database is not allocated by any IMS system when the fuzzy image copy is run, the run time of the image copy is selected as the purge time for the database.

Active allocations on all IMS systems when a fuzzy image copy is taken are considered and the earliest overall purge time is selected as follows when an active allocation is found for an IMS system:

  • Database Image Copy utility was used to create the image copy while the database was available for update processing (CONCUR). A concurrent image copy is a “fuzzy’ copy that occurs when updates are also being done. The data set uses logs in order to complete the image.
  • Database Image Copy 2 utility invoked DFSMS Fast Replication to take an image copy concurrently with update processing (SMSONLC). The image is copy is a “fuzzy” copy so logs must be applied to recover the data set to a usable state.
  • Database Image Copy 2 was used to create the image copy while the database was available for update processing (SMSCIC). The image copy is a “fuzzy” copy so logs must be applied to recover the data set to a usable state.

DBRC uses the checkpoint ID on logs to determine purge times with fuzzy image copies to ensure all updates are included as follows:

  • For full function databases (including HALDBs): A checkpoint ID found on a log volume previous to the start time of the image copy is selected if the checkpoint ID is earlier than the allocation. Otherwise, the allocation time is selected as the purge time.
  • For Fast Path databases: When at least two checkpoints are found on log volumes previous to the start time of the image copy, the log volume start time is used if the start time is earlier than the allocation. Otherwise, the allocation time is selected as the purge time.

If a HALDB Online Reorganization (OLR) is found that can be used as input to recovery for a HALDB that is later than the purge time of the image copy selected, the run time of the OLR is used as the purge time.