Locking Techniques, Types of Locks, DBMS Assignment Help

DBMS - Locking Techniques, Types of Locks, DBMS

DB Projects Help >> Locking techniques

DBMS is often criticized for excessive blocking - resulting in poor performance when the database to share data among multiple concurrent processes. Is this a valid criticism, or is unfairly blamed for DBMS application design and poor execution? To evaluate this question, we must better understand the DBMS locking protocols. In this paper, we analyze how, why, what and when DBMS locks and unlocks the resource base. Future articles will focus on how to minimize the impact of database lock.

The need to block

In an ideal simultaneous multiple processes can simultaneously access data in a DBMS database, each with the look you have exclusive access to the database. In practice, this environment is approximated by the judicious use of locking protocols.

Block at the same time, it is necessary to ensure an environment that a process does not apply for or update a record, which will be updated by another process. The unused part of the control (blocking), would lead to inconsistent and corrupt data.

In addition, record locking, DBMS to implement a variety of other locking mechanisms to ensure the reliability of other data structures, which provide a common I / O, communication between processes, and automatic recovery from a cluster if a process or a failure cluster. Although these structures lock, plus the use of the VMS lock resources, it is rare that hinder competition database, but can actually improve database performance.

How the DBMS applications LOCKS

DBMS makes extensive use of VMS Distributed Lock Manager to control virtually all aspects of database access. Using the Distributed Lock Manager provides a cluster-wide control of data resources so that the DBMS to take advantage of the OpenVMS clustering technology. "

VMS locks consume system resources. A typical DBMS can run hundreds of application lock or thousands of files and database pages at a time. Using a VMS lock for each of these resources in an occupied base could easily deplete these resources. System parameters: LOCKIDTBL, LOCKIDTBL_MAX and parameters REHASHTBL determine the number of locks that are on the system at a time.

To minimize the number of VMS locks required to maintain the integrity and the registration page, DBMS implements a technique called adjustable locking granularity. This allows the DBMS to manage a resource group (pages or files) with a VMS lock. When a request is made contradictory for the same resource group, the process holding the lock is reported that is blocking another process and automatically reduces the level locking the whole group.

Adjustable side locking is required and hidden from the database administrator, while the adjustable record locking can be turned on or off and adjusted for each database. When the adjustable record locking is enabled, the DBMS tries to minimize the number of VMS locks required to maintain data integrity without affecting the simultaneous database.

Types of locks

DBMS employs many types of insurance to ensure data integrity in a simultaneously. By using different types of locks for different functions, DBMS can provide optimum performance in diverse environments.

Area locks

DBMS uses blocks area to implement DML (Data Manipulation Language), the READY message. If the world has prepared a second drive, and then the other operating modes READY-run units are compatible with all commonly used READY mode.

Locks in the region can significantly affect the database simultaneously - however, its impact is felt in a DML READY. Lock contention for the zone blocking only occur when trying to READY a realm. Once you've managed to READY a realm, locking protocols simultaneously (if necessary) are treated to the page and a record high. Table I shows the modes of the borrow area compatible.

Record locks

The locks are usually the main source of lock contention in a DBMS. Record locking is used to control the integrity of your data, and implement "adjustable locking granularity record" function in the DBMS. Adjustable locking is standard for record locking, but can be adjusted or disabled by the DBA.

Quiet point locks

Quiet point locks used to control the database online and after the backup image of the newspaper. Calm, sometimes locking point drop suggests that the processes are waiting online backup to start, or for the primary after-image log file to be written to secondary storage. To minimize the effects (duration) lock point of calm, it is important that all the basic operations of concurrent data (except for recovery operations in the batch) conduct periodic commit (or commit to maintain). Even "Simultaneous Capture" transactions should periodically "commit [preserves]" transactions. This ensures that the online backup will be a "still point" quickly new business to continue.

Freeze Locks

Gel lock used to stop (freeze) the activity database in the recovery process database. When a process terminates abnormally (the result of a process or a node fails, STOP / ID or CTRL-Y/STOP) are all locks held by this process is automatically released. If transactions were allowed to continue, would result in database corruption. So when a process terminates abnormally, DBMS using gel lock to stop the activity database until the failed process (es) can be recovered. Gel locks generally not a major source of contention in most environments. But if you are prone to frequent errors and system processes, or users using CTRL-Y/STOP out of programs that could freeze the locks prevent simultaneous database.

DBMS Assignment Help - Homework Help at Expertsmind.com

Experts at Expertsmind.com offers DBMS homework helpDBMS assignment help and projects help with best online support from qualified and experienced DBMS tutors. We provide optimized database problems and solutions, university assignments and best online tutor for database management course help. Our expert tutors have proven their excellence and we have done many projects in database management system. Find your database question's answers here at Expertsmind.com by just one step ahead by submitting your homework.

Help with Assignments

Why Us ?

Online Instant Experts Tutors

~Experienced Tutors

~24x7 hrs Support

~Plagiarism Free

~Quality of Work

~Time on Delivery

~Privacy of Work