Professional Documents
Culture Documents
Wait Events in RAC Session 362: Longtime Oracle DBA
Wait Events in RAC Session 362: Longtime Oracle DBA
Session 362
Arup Nanda
Longtime Oracle DBA
arup.blogspot.com
What is This?
• RAC Performance Tuning
– I teach a course – Performance Tuning in RAC
• Wait events are useful for understanding the bottlenecks
• All single instance wait events are applicable to RAC
• RAC has some special cases
• This session talks about those RAC-specific wait events
• This is just a subset of the events; not a comprehensive
list
SCN1 SCN2
Checkpoint!
Node 1 Node 2
Database
Wants to
Instance 1 Instance 2
Has
modify it modified
5 it
DB
SMON SMON
LMS LMS
message
buffer
Node 1 Node 2
When node 2 wants a buffer, it sends a message to the
other instance. The message is sent to the LMS (Lock
Management Server) of the other instance. LMS then
sends the buffer to the other instance. LMS is also called
Global Cache Server (GCS).
Wait Events in RAC 9
Grant Scenario 2
1. Check its buffer cache to see if the block exists
2. And the buffer is found. Can Instance1 use it?
Not really. The buffer may be old; it may have been changed
3. LMS of node1 sends message to master of the buffer
3. Master checks the GES and doesn’t sees any lock
4. Instance 1 is granted the global block lock
5. No buffer actually gets transferred
SID1 SID5
SID2 SID6
re
qu
te d
e st
ra n
g
LMS LMS
GRD GES
Instance 2
Instance 1
Database
SID1 SID5
SID2 SID6
LMS LMS
GRD GES
Instance 2
Instance 1 Database
SID1 SID5
SID2 SID6
Master
Instance 2
Requestor Holder
Instance 1 Instance 3
Buffer lock is granted, get from the disk db file scattered|sequential read
1. There is no 3-way grant event, since the request is made to the master
2. There is no 4-way block event; since there will a maximum of 2 hops:
requestor master holder
The 2-way block waits are The cache fusion is taking •Faster interconnect
very high compared to 3-way place as expected, and most •Shorten the run queue
of the blocks are held and
mastered at the same
instance. But most of the
blocks are not found in the
local instance.
The 3-way block waits are Cache fusion is taking place; •Manually remaster the
high compared to 2-way but the master and the object
holder are usually different. •Application partitioning
gc
gccurrent
currentblock
block2-way
request
a v
n e
t r
Q t
u Q
e u
SID1 u SID5 e
e u
e
Session
Session SID3 SID7
be a cause
– Why?
LMS
LMS LMS
LMS
GRD
GRD GES
GES Instance
Instance 2
2