Database Reference
In-Depth Information
Log
File
DATA
BASE
Backup
File
BACKUP
JOURNALIZING
CHECKPOINTING
RECOVERY
DBMS
Figure 17-2
Database recovery system.
Routine Backup and Recovery Activities Let us now summarize the routine
activities for backup and recovery. Here are the major tasks:
Schedule regular backups, at least once a day, more often if the nature of your
database content warrants it. Find a suitable time window on the computer
system to perform the backups. If frequent full backups are not feasible, have
a combination of full and partial backups. Partial backups may be hot backups
while the database is up and running. Recovery is more difficult with partial
backups. Have a good tape management system to make sure that backup tapes
are not scratched before their expiration dates.
Ensure that logging is properly done and that all the necessary details are
written in the log records. Partial backups are more difficult for recovery.
Monitor the space allocation on disk for the log file so that it does not get filled
up before the next archival. Periodically archive the disk log file on other media
such as tape cartridges or optical devices. Keep archived log files in safe
custody.
Monitor the frequency of writing checkpoint records. Writing checkpoint
records results in system overhead. Adjusting the frequency is a balance
between such system overhead and saving time during recovery.
Review your disaster recovery plan on a regular basis. Have a regular sched-
ule to test the recovery process. This will validate your backup files and the log
files. Also, if and when database failure occurs, you will be prepared with a
tested procedure.
Recovery Methods How recovery must be performed depends on the nature
of the failure, the availability of backup and log files, and the extent of the damage.
In failures resulting from disk crashes, depending on how badly the disk gets
destroyed, you may have to discard the current devices and use newer or other
available ones.
In Chapter 15, Figure 15-31 presented a comprehensive database recovery
example. We will now review the applicability of recovery methods to different types
of failures. The underlying principle in recovery involves restoring the database to
Search WWH ::




Custom Search