Question
Which of the following statements about the Two Phase Locking (2PL) protocol is/are TRUE?
Official answer and solution
- Official answer
- A, C and D
- From
- Official GATE 2024 answer key
Solution
Check the properties of Two-Phase Locking: growing/shrinking phases, guaranteed conflict serializability, and susceptibility to deadlock.
- (A) is TRUE: Every schedule permitted by the 2PL protocol is conflict-serializable (and hence serializable), ordered by the transactions' lock points.
- (B) is FALSE: Releasing a lock immediately after an operation and then acquiring another lock for a subsequent operation violates the two-phase rule.
- (C) is TRUE: By definition of 2PL, a transaction has a growing phase (only acquiring locks) followed by a shrinking phase (only releasing locks); once the first lock is released, no further locks can be acquired.
- (D) is TRUE: 2PL does not prevent deadlocks (e.g., holds lock on and waits for , while holds lock on and waits for ).
Final answer
Options (A), (C), (D)
The answer is the one in the official GATE answer key. The solution is this site's own explanation.
Source
- Paper
- GATE 2024 Computer Science and Information Technology - Set 2 (CS2)
- Question
- 27 of 65
- Section
- Computer Science and Information Technology
Report an error in this question
GATE questions are the work of the organising institutes. This site is independent and is not affiliated with them.