Two phase locking (2pl), Database Management System

Two Phase Locking (2PL)

The two-phase locking protocol having of two phases:

Phase 1: The lock acquisition phase: If a transaction T needs to read an object, it wants to obtain the S (shared) lock. If T needs to modify an object, it wants to obtain X (exclusive) lock. No conflicting locks are granted to a transaction. New locks on items can be obtained but no lock can be released till all the locks needed by the transaction are obtained.

Phase 2: Lock Release Phase: The existing locks can be released in any order but no new lock can be obtained after a lock has been released. The locks are held only till they are needed.

Normally the locks are taken by the DBMS. Any legal schedule of transactions that follows 2 phase locking protocol is sured to be serialisable. The 2 phase locking protocol has been confirmed for it correctness. Though, the proof of this protocol is beyond the scope of this Unit. You can refer to more readings for more details on this protocol.


Posted Date: 3/12/2013 2:40:08 AM | Location : United States

Related Discussions:- Two phase locking (2pl), Assignment Help, Ask Question on Two phase locking (2pl), Get Answer, Expert's Help, Two phase locking (2pl) Discussions

Write discussion on Two phase locking (2pl)
Your posts are moderated
Related Questions
Use Delegation to Share Implementation The delegation " Delegation comprises of catching an operation on one object and sending it to other object which is part, or related to

Atomicity: It describes a transaction to be a one unit of processing. We can also say either a transaction will be finished completely or not at all. In the transaction example 1

What is a function group? A function group is a collection of logically related modules that share global data with every other.  All the modules in the group are contained in

Query Processor The query language processor is responsible for taking query language statements or shifting them from the English-like syntax of the query language to a form

While sorting, if the main storage available is not enough, the system writes data to an external help file.  The SAP profile parameter, which determines DIR_SORTTMP

Explain query execution plan? - Optimizer available in SQL Server optimizes code to be effectively executed. - A query execution plan demonstrates how this optimizer would r

Describe domain constraints. Domain constraints contain entity integrity and referential integrity. The domain is a set of values that might be assigned to an attribute. The en

What is a transaction ? The Transaction is a unit of data processing. For instance, many of the transactions at a bank may be withdrawal or deposit of money; transfer of money f

write a database program for concurrency transaction in a bank