LP #1269573: pt-deadlock-logger doesn't log row lock information
Description
Environment
Smart Checklist
Activity

lpjirasync January 24, 2018 at 8:05 PM
**Comment from Launchpad by: Paul Namuag on: 12-11-2014 06:04:53
Also affects current version
[root@localhost ~]# pt-deadlock-logger --version
pt-deadlock-logger 2.2.11

lpjirasync January 24, 2018 at 8:05 PM
**Comment from Launchpad by: Paul Namuag on: 12-11-2014 06:02:39
This is true. I've verified it.
mysql> select * from deadlocks\G
*************************** 1. row ***************************
server: localhost
ts: 2014-11-12 04:49:41
thread: 3459
txn_id: 0
txn_time: 539
user: root
hostname: localhost
ip:
db: test
tbl: testuser
idx: PRIMARY
lock_type: RECORD
lock_mode: X
wait_hold: w
victim: 0
query: update testuser set loginName='john.doe' where uaid=11034
*************************** 2. row ***************************
server: localhost
ts: 2014-11-12 04:49:41
thread: 3460
txn_id: 0
txn_time: 99
user: root
hostname: localhost
ip:
db: test
tbl: testuser
idx: PRIMARY
lock_type: RECORD
lock_mode: X
wait_hold: w
victim: 1
query: update testuser set loginName='paul.namuag' where uaid=9999999

lpjirasync January 24, 2018 at 8:05 PM
**Comment from Launchpad by: Marcelo Altmann on: 13-08-2014 11:27:48
I Agree with Kenny, will be very helpful if the row lock information were also logged.
pt-deadlock-logger --version
pt-deadlock-logger 2.2.10
Details
Assignee
UnassignedUnassignedReporter
lpjirasynclpjirasync(Deactivated)Priority
Low
Details
Details
Assignee
Reporter

Priority
Smart Checklist
Open Smart Checklist
Smart Checklist
Open Smart Checklist
Smart Checklist

**Reported in Launchpad by Kenny Gryp last update 12-11-2014 06:04:53
I don't see a way to log locking information.
Example:
(1) WAITING FOR THIS LOCK TO BE GRANTED:
RECORD LOCKS space id 67 page no 12 n bits 312 index `PRIMARY` of table `db`.`tbl` trx id DB0B9AE88 lock_mode X locks rec but not gap waiting
(2) HOLDS THE LOCK(S):
RECORD LOCKS space id 67 page no 12 n bits 312 index `PRIMARY` of table `db`.`tbl` trx id DB0B9AE86 lock_mode X locks rec but not gap
(2) WAITING FOR THIS LOCK TO BE GRANTED:
RECORD LOCKS space id 60 page no 8 n bits 512 index `PRIMARY` of table `db`.`tbl2` trx id DB0B9AE86 lock_mode X locks rec but not gap waiting
This is necessary to troubleshoot some deadlocks which are not obvious (when using triggers).
$ ./pt-deadlock-logger --version
pt-deadlock-logger 2.2.6