PDF (A4) - 40.1Mb
Man Pages (TGZ) - 259.0Kb
Man Pages (Zip) - 366.2Kb
Info (Gzip) - 4.0Mb
Info (Zip) - 4.0Mb
Thecluster_locks table provides information about current lock requests holding and waiting for locks onNDB tables in an NDB Cluster, and is intended as a companion table tocluster_operations. Information obtain from thecluster_locks table may be useful in investigating stalls and deadlocks.
Thecluster_locks table contains the following columns:
node_idID of reporting node
block_instanceID of reporting LDM instance
tableidID of table containing this row
fragmentidID of fragment containing locked row
rowidID of locked row
transidTransaction ID
modeLock request mode
stateLock state
detailWhether this is first holding lock in row lock queue
opOperation type
duration_millisMilliseconds spent waiting or holding lock
lock_numID of lock object
waiting_forWaiting for lock with this ID
Notes
The table ID (tableid column) is assigned internally, and is the same as that used in otherndbinfo tables. It is also shown in the output ofndb_show_tables.
The transaction ID (transid column) is the identifier generated by the NDB API for the transaction requesting or holding the current lock.
Themode column shows the lock mode; this is always one ofS (indicating a shared lock) orX (an exclusive lock). If a transaction holds an exclusive lock on a given row, all other locks on that row have the same transaction ID.
Thestate column shows the lock state. Its value is always one ofH (holding) orW (waiting). A waiting lock request waits for a lock held by a different transaction.
When thedetail column contains a* (asterisk character), this means that this lock is the first holding lock in the affected row's lock queue; otherwise, this column is empty. This information can be used to help identify the unique entries in a list of lock requests.
Theop column shows the type of operation requesting the lock. This is always one of the valuesREAD,INSERT,UPDATE,DELETE,SCAN, orREFRESH.
Theduration_millis column shows the number of milliseconds for which this lock request has been waiting or holding the lock. This is reset to 0 when a lock is granted for a waiting request.
The lock ID (lockid column) is unique to this node and block instance.
The lock state is shown in thelock_state column; if this isW, the lock is waiting to be granted, and thewaiting_for column shows the lock ID of the lock object this request is waiting for. Otherwise, thewaiting_for column is empty.waiting_for can refer only to locks on the same row, as identified bynode_id,block_instance,tableid,fragmentid, androwid.
PDF (A4) - 40.1Mb
Man Pages (TGZ) - 259.0Kb
Man Pages (Zip) - 366.2Kb
Info (Gzip) - 4.0Mb
Info (Zip) - 4.0Mb