--通过SQL查看SID,
select trunc((sysdate-a.logon_time)*24*60,2) minutes,
a.event,
a.p1,
a.P1TEXT,
a.p2,
a.P2TEXT,
a.p3,
a.P3TEXT,
'alter system kill session '''||a.SID||','||a.SERIAL#||',@'||a.INST_ID||''';',
a.username,
a.sid,
a.serial# ,
(SELECT 'kill -9 '||SPID FROM V$PROCESS WHERE ADDR=a.PADDR) pid,
a.BLOCKING_INSTANCE,
a.BLOCKING_SESSION,
a.program,
a.machine,
a.osuser,
a.status,
a.inst_id,
a.sql_id,
a.sql_child_number,
b.sql_text,
b.SQL_FULLTEXT
from gv$session a, gv$sql b
where
a.inst_id=b.inst_id
and a.sql_address = b.address
and a.STATUS='ACTIVE'
and a.sql_hash_value = b.hash_value
and a.sql_child_number=b.child_number
-- and (sysdate-a.logon_time)*24*60>1000
--and a.username like '%MOBILE_V2%'
-- and program in('i-Signal.exe','plsqldev.exe')
--and program like 'sqlldr@localhost.loc%'
order by 1 desc
本站仅提供存储服务,所有内容均由用户发布,如发现有害或侵权内容,请
点击举报。