oracle session locked

列出停滯的使用者session

select * from v$session where username=’xxx’
and last_call_et > 65000

delete v$session where sid=9

select  * from v$lock

SELECT s.sid,
s.serial#,
s.osuser,
s.program
FROM   v$session s
where username=’xxx’ and last_call_et > 65000;

刪除session

ALTER SYSTEM KILL SESSION ‘9,43728’ IMMEDIATE;
ALTER SYSTEM KILL SESSION ‘14,22737’ IMMEDIATE;

SELECT ‘ALTER SYSTEM KILL SESSION “‘ || s.sid ||
‘,’ || s.serial# || “‘ IMMEDIATE;’
FROM   v$session s
where username=’xxx’ and last_call_et > 65000;

發表迴響

你的電子郵件位址並不會被公開。 必要欄位標記為 *

What is 12 + 12 ?
Please leave these two fields as-is:
IMPORTANT! To be able to proceed, you need to solve the following simple math (so we know that you are a human) :-)