정미나닷컴
[Oracle] 오라클 Lock 찾아서 Kill 하기 본문
Search Lock
SELECT T1.object_name, DECODE(locked_mode, 2, 'ROW SHARE', 3, 'ROW EXCLUSIVE', 4, 'SHARE', 5, 'SHARE ROW EXCLUSIVE', 6, 'EXCLUSIVE', 'UNKNOWN') lock_mode
FROM dba_objects T1, v$locked_object T2
WHERE T1.object_id = T2.object_id;
select *
from
(select * from v$locked_object where oracle_username = 'ESMCONSOLE') aa,
(select object_id,object_name from dba_objects) bb
where aa.object_id = bb.object_id(+)
Kill Lock
- search serial number
select
a.session_id as SESSION_ID,
b.serial# as SERIAL_NO,
a.os_user_name as OS_USER_NAME,
a.oracle_username as ORACLE_USERNAME,
b.status as STATUS
from v$locked_object a, v$session b
where a.session_id = b.sid;
- kill
alter system kill session 'SESSION_ID, SERIAL_
'IT' 카테고리의 다른 글
웹 표준 항목 (0) | 2010.03.09 |
---|---|
NATE ON 방화벽 뚫기 (1) | 2010.03.09 |
FCKeditor 폼 체크 (0) | 2010.03.09 |
[HTML4] table 바깥으로 이미지 고정 (0) | 2010.03.09 |
두 점 사이의 각도 구하기 (0) | 2010.03.09 |