Guenadi N Jilevski's Oracle BLOG


Overview of global enqueue waits

Overview of global enqueue waits

In a RAC database, the GES is responsible for inter-instance resource coordination. The GES manages all cache fusion inter-instance resource optimization. It tracks the status of all Oracle enqueue mechanisms for resources that are accessed by more than one instance. Oracle uses GES to manage concurrency for resources on transactions, tables and other structures within a RAC environment. GES is an integrated RAC component that coordinates global locks between the instances in the cluster.  Block access and update are recorded in GRD, which is a virtual memory structure spanning across all instances. GES controls all library cache locks and dictionary cache locks in the database.  These resources are local in a single instance database and global in a RAC database. Global locks are also used to protect data structures used for a transaction management.  GES performs most of its activities using the LMD0 and LCK0 background processes. In general processes communicate with their local LMD0 process to manipulate the global resources. The local LMD0 process communicates with LMD0 process on other instances. The LCK0 background process is used to obtain locks that are required by the entire instance. For example LCK0 is responsible for maintaining dictionary cache locks.

A resource is a memory structure that represents some component of the database to which access must be restricted or serialized. In other words, the resource can only be accessed by one process or one instance at a time. If the resources is currently in use, other processes or instances needing to access the resource must wait in a queue until the resource becomes available.

An enqueue is a memory structure that serializes access to a particular resource. If the resource is only required by the local instance, then the enque can be required locally, and no coordination is necessary. However, if the resource is required by a remote instance, then the local enque must become global.

Let’s make an overview of the global enqueue waits in RAC.  Enqueue in RAC are global in order to have coherency for enqueues across all the instances and they are synchronous.

Most common enqueue are listed below

TX – transaction enqueue representing either row lock waits or ITL waits

TM – table manipulation enqueue on any table with DML. For example update block in one instance and truncate, drop or collect statistics  in another instance on the same table.

HW – high watermark enqueue when there is extending of HW on a segment

TA – transaction recovery enqueue

SQ – sequence generation enqueue

US – undo segment enqueue for managing undo segments extension

The waits may constitute serious serialization points because enqueue are often even in a single instance and in RAC in addition to serialization that occurs due to enqueus they are exacerbated due to the private interconnect latency.  If something does not scale well in a single instance it will not scale well in RAC due to contention problems and additional overhead contributed by the private interconnect latencies.

December 13, 2009 - Posted by | oracle

No comments yet.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: