Deferred Update Transaction Recovery
Deferred Update Transaction Recovery
• Immediate Update:
• • Updates applied during transaction
execution.
• • Requires both undo and redo logs.
Given Log Entries
• [START T1]
• [START T7]
• [WRITE T1, A, 100]
• [WRITE T7, B, 200]
• [COMMIT T1]
• [WRITE T7, C, 300]
• [COMMIT T7]
Crash After Log Entry 6
• • Crash occurs after [WRITE T7, C, 300] but
before [COMMIT T7].
• • T1 has committed; T7 has not.
• • Use deferred update recovery strategy.
Recovery in Deferred Update
• • Apply updates of committed transactions
only.
• • T1 committed → Apply changes (A = 100).
• • T7 not committed → Discard changes (B and
C remain unchanged).
Final Database State
• • A = 100 (from T1, committed).
• • B = original value (T7 uncommitted).
• • C = original value (T7 uncommitted).
Summary
• • Deferred update avoids undo operations by
delaying updates until commit.
• • During crash recovery, only committed
transactions are redone.
• • Uncommitted transactions are ignored.
Thank You
• Prepared for: DBMS - Semester 4
• University: Mumbai University
• Topic: Log-Based Recovery using Deferred
Update