Database recovery, in its simplest form, is the restoration of a database after its (partial) destruction due to some failure.
In order to facilitate this process, some forward planning needs to be done. Periodically, a copy of the data in the database is saved.
This copy is normally referred to as a backup or image copy. These image copies can reside on DASD or cartridges. Though this process can be done anytime, it is normally done when there is no other database activity at the same time.
This creates a complete backup. There are other strategies for taking a database backup, but they will not be discussed in this book. In addition to taking an image copy of the database(s), all changes made to the data in the database can be logged and saved, at least until the next image copy. These changes are contained in data sets called log data sets. This provides a complete recovery environment so that no data is lost in the event of a system or application failure.
There is an IMS facility called database recovery control (DBRC) which provides database integrity and can be used to help ensure that there is always a recovery process available. The use of DBRC to control database backup and recovery is not mandatory, but is highly recommended.
When you need DBRC recovery in IMS DB
- A DLI batch update job fails after making at least one database update.
- A failure has occurred on a physical DASD device.
- A failure has occurred in a database recovery utility.
- A failure of dynamic backout or batch backout utility has occurred.
- An IMS online system failure and emergency restart has not been completed.