全部博文(136)
分类: Oracle
2008-04-14 11:20:55
ORA-04021 timeout occurred while waiting to lock object stringstringstringstringstring Cause: While waiting to lock a library object, a timeout is occurred. Action: Retry the operation later. |
请输入用户名: yuechaotian/test 连接到: Oracle9i With the Partitioning, OLAP and Oracle Data Mining options JServer Release SQL> select distinct sid from v$mystat; SID ---------- 11 SQL> CREATE OR REPLACE PROCEDURE prc_test_lock 2 IS 3 BEGIN 4 WHILE TRUE 5 NULL; 6 END 7 END; 8 / 过程已创建。 SQL> exec prc_test_lock; ... --处于死循环中 ... |
请输入用户名: yuechaotian/test 连接到: Oracle9i With the Partitioning, OLAP and Oracle Data Mining options JServer Release SQL> select distinct sid from v$mystat; SID ---------- 12 SQL> CREATE OR REPLACE PROCEDURE prc_test_lock 2 IS 3 v_temp VARCHAR2(10); 4 BEGIN 5 WHILE TRUE 6 NULL; 7 END 8 END; 9 / ...
-- 处于等待中,一段时间后,出现如下错误: CREATE OR REPLACE PROCEDURE prc_test_lock
|
SQL> conn / as sysdba SQL> select distinct sid from v$mystat; SID ---------- 19 SQL> select EVENT from v$session_wait where sid=12; EVENT ------------------- library cache pin |
2 FROM V$SESSION s, sys.x$kglob o, sys.x$kglpn p 3 WHERE upper(o.kglnaobj) LIKE upper('%prc_test_lock%') 4 AND p.kglpnhdl = o.kglhdadr 5 AND s.SADDR = p.kglpnuse; (session) - username ------------------------------------------------------ (11) - TEST (19) - SYS |
SQL> exec prc_test_lock; BEGIN prc_test_lock; END; * ERROR 位于第 1 行: ORA-00028: 您的会话己被删去 SQL> |