buffer pool latch和cache buffers chains latch

来源:互联网 发布:windows找不到chrome 编辑:程序博客网 时间:2024/05/17 22:56
<pre name="code" class="sql">buffer pool latch 是用来保护buffer pool的每个buffer pool有一个buffer pool latch保护SQL> select addr,LATCH#,LEVEL#,CHILD#,NAME from v$latch_children where name='buffer pool';ADDR     LATCH#LEVEL#   CHILD# NAME-------- ---------- ---------- ---------- ----------------------------------------------------------------2CD760A8146     18 buffer pool2CD75F78146     17 buffer pool2CD75E48146     16 buffer pool2CD75D18146     15 buffer pool2CD75BE8146     14 buffer pool2CD75AB8146     13 buffer pool2CD75988146     12 buffer pool2CD75858146     11 buffer pool已选择8行。cache buffers chains latch是用来保护 hash  buckets:SQL> SELECT x.ksppinm NAME, y.ksppstvl VALUE, x.ksppdesc describ  FROM x$ksppi x, x$ksppcv y WHERE x.inst_id = USERENV('Instance')   AND y.inst_id = USERENV('Instance')   AND x.indx = y.indx   AND x.ksppinm LIKE '%_db_block_hash%'  2    3    4    5    6  ;NAME       VALUE DESCRIB------------------------------ ---------- ------------------------------_db_block_hash_buckets       16384 Number of database block hash  buckets_db_block_hash_latches       1024 Number of database block hash  Latches可以用下面查询计算cache buffers chains latch的数量:SQL> select count(*) from v$latch_children a,v$latchname b where a.latch#=b.latch# and b.name='cache buffers chains';  COUNT(*)----------      1024根据我们的查询,那么一个cache buffers chains latch 平均下来要管理Select 16384/1024 from dual 16个块.


                                             
0 0