

Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
This is the one numerical problem solved of transaction log recovery technique of Database management system
Typology: Cheat Sheet
1 / 3
This page cannot be seen from the preview
Don't miss anything!


Q7. What is recoverable and nonrecoverable schedule? Explain with example.
Recoverable Schedule: A schedule is recoverable if a transaction commits only after all the transactions from which it has read have committed.
Example: T1: r1(X) w1(X) Commit T2: r2(X) Commit Here, T2 reads X written by T1, and T1 commits before T2, so it's recoverable.
Non-Recoverable Schedule: If a transaction commits before the transaction it has read from commits, the schedule is non-recoverable.
Example: T1: r1(X) w1(X) T2: r2(X) Commit Abort If T1 aborts after T2 commits, then T2 has read dirty data, hence it's non-recoverable.
Deadlock and Two Approaches to Deadlock Prevention: Deadlock: Occurs when two or more transactions wait indefinitely for each other to release locks.
Approaches:
Serializability Check:
Schedule S1: T1: r1(X) r1(Z) w1(X) T2: r2(Y) r2(Z) w2(Z) w2(Y) T3: r3(X) r3(Y) w3(Y)
Conflicts: T1 -> T3 (w1(X) -> r3(X)) T3 -> T2 (w3(Y) -> w2(Y)) T2 -> T1 (w2(Z) -> r1(Z)) Graph has a cycle -> Not serializable
Schedule S2: T1: r1(X) r1(Z) w1(X) T2: r2(Y) r2(Z) r2(Y) w2(Z) w2(Y) T3: r3(X) r3(Y) w3(Y)
Conflicts: