ITPEC FE Morning October 2020 Question 28
When a failure occurs in a storage unit that stores a database, which of the following is an operation that can recover the database by using backup files and a log?
Explanation
Rollforward — after a media failure, restore the latest backup and reapply the logged updates made since.
A storage failure destroys the database files themselves. Recovery has two steps:
- •Restore the most recent backup copy onto a working device; the database is now as it was when the backup was taken
- •Read the after-images of committed transactions from the log and reapply them in order, bringing the database up to the moment of failure
The second step is rollforward (redo). Its counterpart, rollback (undo), uses before-images to cancel the work of transactions that had not committed.
Answer (d)
Why not others:
- •(a) Archive — keeps copies of data or logs for long-term storage; it makes recovery possible but is not the recovery operation
- •(b) Checkpoint dump — periodically writes buffered data to disk so that recovery after a system crash can start from the checkpoint; it does not rebuild a lost storage unit
- •(c) Commit — makes a transaction's updates final during normal processing; it is not a recovery step
Key rule: Media failure: restore the backup and roll forward with after-images. Transaction or system failure: roll back unfinished work with before-images.
Databases · AI-written, may contain errors
This question comes from an official ITPEC past paper. ITPEC Practice is an independent study tool and is not affiliated with ITPEC. See the official FE past-paper collection or Report an issue.