Skip to end of metadata
Go to start of metadata

There are enqueue lock entries which are older than several hours or days in sm12:

Select the lock entry and click the "Details" button, you can see detailed info of the lock entry:

From the detail screen,  you can see "Lock Owner" (the lock owner ID), "Host name" (the host name where the lock was requested) and "Date" (the timestamp of the lock request). Also, "Work Process" (the request was made by a program running on work process #50). Normally, the work process who was process the "Enqueue" operation will also process "Dequeue" operation, therefore,  You can move to the instance on the "Host name", and open the developer trace file.

However, there is also special situation, to see any actions which involve this "Lock" widely, you can search:

SM51 -> Select the "Host name" -> Goto -> Server Name -> Information -> Trace Search, using Lock Owner ID as key word.

In this example, the Lock Owner ID is 20151104041433010000015001SISR1102A

From T_cd:st11, open the work process trace file, using the lock detail info ("Date", or "Lock Owner")to search again.

In this example, work process is 50 dev_w50, the "Lock Owner" is 20151104041433010000015001SISR1102A, and the timestamp is around 2015 11 04 04:14:33

dev_w50:
=========================================
M Wed Nov 04 04:14:46 2015
M  *** ERROR => no enqueue name set [thxxmsg.c    459]
M  {root-id=0050560202551EE5A0CBE3973538B0FC}_{conn-id=00000000000000000000000000000000}_0
M  ***LOG GI0=>  [enctrl.c     1250]
M  ***LOG GI2=>   [enctrl.c     1250]
E  *** ERROR => ThToEnq(). rtc = -1 [enctrl.c     1252]
E  {root-id=0050560202551EE5A0CBE3973538B0FC}_{conn-id=00000000000000000000000000000000}_0
E  *** ERROR => Enqueue: EnqTskhClient() errror 8 [enxxhead.c   3189]
E  {root-id=0050560202551EE5A0CBE3973538B0FC}_{conn-id=00000000000000000000000000000000}_0
M  ***LOG GI0=>  [enctrl.c     2395]
M  ***LOG GI4=>   [enctrl.c     2395]
E  *** ERROR => DequeAll() failed. Returncode = 8 [enctrl.c     2397]
E  {root-id=0050560202551EE5A0CBE3973538B0FC}_{conn-id=00000000000000000000000000000000}_0
E  *** ERROR => Owner = 20151104041433010000005001SISR1102A......................., ReturnCode = 8 [enctrl.c     2399]
E  {root-id=0050560202551EE5A0CBE3973538B0FC}_{conn-id=00000000000000000000000000000000}_0
E  client:          000
E  user:            SAPSYS
E  tcode:
E  calling program: RSPOWP00
E  dynpro no.:      2000
E  dynpro group:
M  *** ERROR => no enqueue name set [thxxmsg.c    459]
M  {root-id=0050560202551EE5A0CBE3973538B0FC}_{conn-id=00000000000000000000000000000000}_0
M  ***LOG GI0=>  [enctrl.c     1250]
M  ***LOG GI2=>   [enctrl.c     1250]
E  *** ERROR => ThToEnq(). rtc = -1 [enctrl.c     1252]
E  {root-id=0050560202551EE5A0CBE3973538B0FC}_{conn-id=00000000000000000000000000000000}_0
E  *** ERROR => Enqueue: EnqTskhClient() errror 8 [enxxhead.c   3189]
E  {root-id=0050560202551EE5A0CBE3973538B0FC}_{conn-id=00000000000000000000000000000000}_0
M  ***LOG GI0=>  [enctrl.c     2395]
M  ***LOG GI4=>   [enctrl.c     2395]
E  *** ERROR => DequeAll() failed. Returncode = 8 [enctrl.c     2397]
E  {root-id=0050560202551EE5A0CBE3973538B0FC}_{conn-id=00000000000000000000000000000000}_0
E  *** ERROR => Owner = 20151104041433010000015001SISR1102A......................., ReturnCode = 8 [enctrl.c     2399]
E  {root-id=0050560202551EE5A0CBE3973538B0FC}_{conn-id=00000000000000000000000000000000}_0
E  client:          000
E  user:            SAPSYS
E  tcode:
E  calling program: RSPOWP00
E  dynpro no.:      2000
E  dynpro group:

The Lock Owner ID was appeared at Wed Nov 04 04:14:46 2015. You can find that the Deque operation got failed. The program actually tried to dequeu but failed. That's why the lock entry remained in SM12. This means that the lock can be manually deleted now. The reason of the DequeAll failure is not the main point of this Wiki.