You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-dev@db.apache.org by "Kim Haase (JIRA)" <ji...@apache.org> on 2014/09/08 16:22:28 UTC

[jira] [Closed] (DERBY-360) Add doc info to print lock table for timeout errors

     [ https://issues.apache.org/jira/browse/DERBY-360?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Kim Haase closed DERBY-360.
---------------------------
    Resolution: Won't Fix

There's a good deal of information on debugging deadlocks in both the Admin Guide and the Developer's Guide, so this problem has not been perceived for a long time.

> Add doc info  to print lock table for timeout errors
> ----------------------------------------------------
>
>                 Key: DERBY-360
>                 URL: https://issues.apache.org/jira/browse/DERBY-360
>             Project: Derby
>          Issue Type: Improvement
>          Components: Documentation
>            Reporter: Sunitha Kambhampati
>            Priority: Minor
>
> In version 10.1 docs, 
> 1. Admin guide - http://incubator.apache.org/derby/docs/adminguide/cadminlockvti83889.html, also a small section on timeouts should be added. 
> To debug lock timeout errors, set derby.locks.monitor=true and derby.locks.deadlockTrace=true this will print the lock table information to the derby.log when the timeout happens.  If you also set the derby.language.logStatementText=true , then all the statement executed on the system will be written out to the derby.log. Statement information also includes the transaction id on which the statement is being executed.  Using the transaction id that is holding the lock in the lock table dump if you do a reverse search for the transaction id in derby.log, it is possible to narrow down which statements may be holding the locks. 
> --------------
> Here is an example of lock table dump in derby.log  on a lock timeout:
> ERROR 40XL2: A lock could not be obtained within the time requested.  The lockTable dump is:
> 2005-06-14 18:39:15.788 GMT
> XID       |TYPE         |MODE|LOCKCOUNT|LOCKNAME
> --------------------------------------------------------------------------------------
> *** The following row is the victim ***
> 146       |ROW          |S   |0        |(1,14)
> *** The above row is the victim ***
> 139       |TABLE        |IX  |1        |Tablelock
> 146       |TABLE        |IS  |1        |Tablelock
> 139       |ROW          |X   |1        |(1,14)
> --------------------------------------------------------------------------------------



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)