转自 http://tolywang.itpub.net/post/48/70906
概述
造成数据库性能下降或挂起的原因很多,”library cache pin”等待是其中之一.当数据库性能严重下降或挂起时,我们通过查询v$session_wait,发现大量的”library cache pin”等待,查询的SQL语句如下:
#su - oracle
$svrmgrl
svrmgr>connect internal
svrmgr>select sid,event,p1,p2,p3 from v$session_wait where wait_time=0;
SID EVENT P1 P2 P3
———- ————————- ———- ———- ————–
9 library cache pin 15417016 10090832 20
154 library cache pin 15417016 11224168 20
341 library cache pin 15417016 11449936 20
349 library cache pin 15417016 16489792 20
390 library cache pin 15417016 11992536 20
160 library cache pin 15417016 6166600 20
20 library cache pin 15417016 10868760 20
