Friday, 29 August 2014

Wait Event: Cache buffer LRU chain latch

Wait Event: Cache buffer LRU chain latch

Possible Causes:

  • Processes need to get this latch when they need to move buffers based on the LRU block replacement policy in the buffer cacheThe cache buffer lru chain latch is acquired in order to introduce a new block into the buffer cache and when writing a buffer back to disk, specifically when trying  to scan the LRU (least recently used) chain containing all the dirty blocks in the buffer cache.
  • Competition for the cache buffers lru chain latch is symptomatic of intense buffer cacheactivity caused by inefficient SQL statements. Statements that repeatedly scan large unselective indexes or perform full table scans are the prime culprits. 
  • Heavy contention for this latch is generally due to heavy buffer cache activity which can be caused, for example, by: Repeatedly scanning large unselective indexes
Actions:
  • Contention in this latch can be avoided implementing multiple buffer pools or increasing the number of LRU latches with the parameter DB_BLOCK_LRU_LATCHES (The default value is generallysufficient for most systems).
  • Its possible to reduce contention for the cache bufferlru chain latch by increasing the size of the buffer cache and thereby reducing the rate at which new blocks are introduced into the buffer cache

Ref:
WAITEVENT: "latch free" Reference Note (Doc ID 34576.1)
gavinsoorma.com

No comments: