Transactions
August 29, 2024
UGC NET CS 2006 Dec-paper-2
August 29, 2024
Transactions
August 29, 2024
UGC NET CS 2006 Dec-paper-2
August 29, 2024

Database-Management-System

Question 612
Two phase protocol in a database management system is :
A
a concurrency mechanism that is not deadlock free
B
a recovery protocol used for restoring a database after a crash
C
Any update to the system log done in 2-phases
D
not effective in Database
Question 612 Explanation: 
The two phase protocol in DBMS refers to a protocol in which locking and unlocking of shared data includes two phases:
1. Growing Phase: In this locks are acquired according to the need as the transaction proceeds.
2. Shrinking Phase: In this release locks as transaction starts reaching to completion.
A transaction can obtain locks but can’t release locks in growing phase. Similarly a transaction can release locks but can’t obtain lock in shrinking phase.
There are various types of two phase locking mechanism which can provide a conflict serializable schedule but can’t provide a schedule which is deadlock free and can be implemented practically.
Correct Answer: A
Question 612 Explanation: 
The two phase protocol in DBMS refers to a protocol in which locking and unlocking of shared data includes two phases:
1. Growing Phase: In this locks are acquired according to the need as the transaction proceeds.
2. Shrinking Phase: In this release locks as transaction starts reaching to completion.
A transaction can obtain locks but can’t release locks in growing phase. Similarly a transaction can release locks but can’t obtain lock in shrinking phase.
There are various types of two phase locking mechanism which can provide a conflict serializable schedule but can’t provide a schedule which is deadlock free and can be implemented practically.

Leave a Reply

Your email address will not be published. Required fields are marked *