1.查看数据库中需要关注的等待事件:
select sw.seq#,sw.sid||','||s.serial# sids,s.username,sw.event,sw.P1,sw.p2,sw.p3,sw.wait_time "WAIT", sw.state,sw.seconds_in_wait sec,s.status,to_char(s.logon_time,'dd/hh24:mi:ss') logon_time from v$session s,v$session_wait sw where sw.sid =s.sid and s.username is not null and sw.event not like '%SQL*Net%' and sw.event not like 'PX Deq%' and sw.event not like 'rdbms ipc message' order by sw.event,s.username ;select sw.s