1 - Enable standard SQL_TRACE functionality (Default)
4 - As Level 1 PLUS trace bind values
8 - As Level 1 PLUS trace waits
This is especially useful for spotting latch wait etc.
but can also be used to spot full table scans and index scans.
12 - As Level 1 PLUS both trace bind values and waits
SELECT spid FROM v$process
WHERE v$process.addr = (
SELECT v$session.paddr
FROM v$session
WHERE v$session.SID = &mysid
);
Enter value for mysid: 31
old 5: WHERE v$session.SID = &mysid
new 5: WHERE v$session.SID = 31
SPID
------------
8166
oradebug setospid 8166
Oracle pid: 22, Unix process pid: 8166, image: oracle@kdtz1 (SMON)
oradebug unlimit
oradebug event 10046 trace name context forever, level 12;
oradebug tracefile_name
/oracle/app/oracle/admin/ucis/bdump/ucis1_smon_8166.trc
oradebug event 10046 trace name context off [@more@]来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/48010/viewspace-1016356/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/48010/viewspace-1016356/