How to find what causes ORA-00054?

For some time, I noticed that we get an error ORA-00054when trying to release SELECT ... FOR UPDATE NOWAITduring a large number of simultaneous updates for db. This is our development system, and we really don't have another user, or at least that's what we believe in.

We went through the logs of our application, and everything seems to be in order; no thread is trying to update the same line.

How can I configure Oracle db to create a log in which I would like to know the user ID that contains the lock when this error occurs?

+3
source share
3 answers

: ORA-00054: NOWAIT

sql, username, machine, port ,

SELECT O.OBJECT_NAME, S.SID, S.SERIAL#, P.SPID, S.PROGRAM,S.USERNAME,
S.MACHINE,S.PORT , S.LOGON_TIME,SQ.SQL_FULLTEXT 
FROM V$LOCKED_OBJECT L, DBA_OBJECTS O, V$SESSION S, 
V$PROCESS P, V$SQL SQ 
WHERE L.OBJECT_ID = O.OBJECT_ID 
AND L.SESSION_ID = S.SID AND S.PADDR = P.ADDR 
AND S.SQL_ADDRESS = SQ.ADDRESS;
+6

NOWAIT DBA_BLOCKERS/DBA_WAITERS.

+3

Please use

select * from v$locked_object 

for lock information

Since this is a development environment, you can try the approach outlined in the link below.

https://forums.oracle.com/forums/thread.jspa?threadID=324530

A more complete approach is provided by blocking v $ at the link below

http://www.orafaq.com/node/854

+1
source

All Articles