Why Don Burleson's "get_busy.ksh" does'nt work? [message #64893] |
Thu, 26 February 2004 18:17  |
Tian Maohuai
Messages: 23 Registered: December 2003
|
Junior Member |
|
|
In the Don's book "Oracle High-Performance Tuning with STATSPACK",a script called "get_busy.ksh",it says:
select ... from v$session_wait a,dba_data_files b where a.pl=b.file_id
but I see that the data of a.pl and b.file_id will never equal,the a.pl is very big,and b.file is small,how can they equal?
who knows why?
|
|
|
Re: Why Don Burleson's "get_busy.ksh" does'nt work? [message #64901 is a reply to message #64893] |
Sun, 29 February 2004 04:49   |
Thiru
Messages: 1089 Registered: May 2002
|
Senior Member |
|
|
Hi,
For an event wait like 'buffer busy waits' , v$session_wait.P1 should reflect the file_id . P1,P2,P3 of v$session_wait changes depending on the actual 'wait' that is happening at that time. P1 will not be equal to the file# always. It might indicate something else , for a different wait.
for eg)
thiru@9.2.0:SQL>select * from v$event_name where name in ('buffer busy waits');
EVENT# NAME PARAMETER1
---------- ------------------------------ ------------------------------------------
PARAMETER2 PARAMETER3
---------------------------------------------------------------- -------------------
145 buffer busy waits file#
block# id
-- as seen above, for buffer busy wait,P1 is file#
thiru@9.2.0:SQL>select * from v$event_name where name in ('latch free');
EVENT# NAME PARAMETER1
---------- ------------------------------ --------------------------------------
PARAMETER2 PARAMETER3
---------------------------------------------------------------- ---------------
3 latch free address
number tries
-- for latch free event ,P1 is 'address'
|
|
|
|
|