设为首页 加入收藏

TOP

MySQL RC模式insert update 可能死锁的情况(二)
2017-07-14 10:22:51 】 浏览:4445
Tags:MySQL 模式 insert update 可能 情况
no 3 n bits 96 index PRIMARY of table `test`.`testlll` trx id 322809 lock_mode X(LOCK_X) locks rec but not gap(LOCK_REC_NOT_GAP)
Record lock, heap no 25 PHYSICAL RECORD: n_fields 4; compact format; info bits 0
 0: len 4; hex 80000019; asc ;;
 1: len 6; hex 00000004ecf9; asc ;;
 2: len 7; hex f0000001f90110; asc ;;
 3: len 7; hex 67616f70656e67; asc gaopeng;;


---lock strcut(3):(Add by gaopeng) In modify Version I force check all REC_LOCK/TAB_LOCK for this Trx
RECORD LOCKS space id 434 page no 3 n bits 96 index PRIMARY of table `test`.`testlll` trx id 322809 lock_mode X(LOCK_X) locks rec but not gap(LOCK_REC_NOT_GAP) waiting(LOCK_WAIT)
Record lock, heap no 20 PHYSICAL RECORD: n_fields 4; compact format; info bits 0
 0: len 4; hex 80000018; asc ;;
 1: len 6; hex 00000004ecf8; asc ;;
 2: len 7; hex ef000001f80110; asc ;;
 3: len 7; hex 67616f70656e67; asc gaopeng;;


---TRANSACTION 322808, ACTIVE 43 sec starting index read
mysql tables in use 1, locked 1
LOCK WAIT 3 lock struct(s), heap size 1160, 2 row lock(s), undo log entries 1
MySQL thread id 2, OS thread handle 140734663980800, query id 408 localhost root updating
update testlll set name='gaopeng1' where id=25
------- TRX HAS BEEN WAITING 5 SEC FOR THIS LOCK TO BE GRANTED:
RECORD LOCKS space id 434 page no 3 n bits 96 index PRIMARY of table `test`.`testlll` trx id 322808 lock_mode X(LOCK_X) locks rec but not gap(LOCK_REC_NOT_GAP) waiting(LOCK_WAIT)
Record lock, heap no 25 PHYSICAL RECORD: n_fields 4; compact format; info bits 0
 0: len 4; hex 80000019; asc ;;
 1: len 6; hex 00000004ecf9; asc ;;
 2: len 7; hex f0000001f90110; asc ;;
 3: len 7; hex 67616f70656e67; asc gaopeng;;


------------------
---lock strcut(1):(Add by gaopeng) In modify Version I force check all REC_LOCK/TAB_LOCK for this Trx
TABLE LOCK table `test`.`testlll` trx id 322808 lock mode IX
---lock strcut(2):(Add by gaopeng) In modify Version I force check all REC_LOCK/TAB_LOCK for this Trx
RECORD LOCKS space id 434 page no 3 n bits 96 index PRIMARY of table `test`.`testlll` trx id 322808 lock_mode X(LOCK_X) locks rec but not gap(LOCK_REC_NOT_GAP) waiting(LOCK_WAIT)
Record lock, heap no 25 PHYSICAL RECORD: n_fields 4; compact format; info bits 0
 0: len 4; hex 80000019; asc ;;
 1: len 6; hex 00000004ecf9; asc ;;
 2: len 7; hex f0000001f90110; asc ;;
 3: len 7; hex 67616f70656e67; asc gaopeng;;


---lock strcut(3):(Add by gaopeng) In modify Version I force check all REC_LOCK/TAB_LOCK for this Trx
RECORD LOCKS space id 434 page no 3 n bits 96 index PRIMARY of table `test`.`testlll` trx id 322808 lock_mode X(LOCK_X) locks rec but not gap(LOCK_REC_NOT_GAP)
Record lock, heap no 20 PHYSICAL RECORD: n_fields 4; compact format; info bits 0
 0: len 4; hex 80000018; asc ;;
 1: len 6; hex 00000004ecf8; asc ;;
 2: len 7; hex ef000001f80110; asc ;;
 3: len 7; hex 67616f70656e67; asc gaopeng;;
情况2
update
update


TX1:                                                                    TX2:
update testlll set name='gaopeng1' where id=22;
                                                                            update testlll set name='gaopeng1' w

首页 上一页 1 2 3 4 下一页 尾页 2/4/4
】【打印繁体】【投稿】【收藏】 【推荐】【举报】【评论】 【关闭】 【返回顶部
上一篇MYSQL INNODB主键使用varchar和in.. 下一篇RHEL 5.7 使用rpm安装XtraBackup..

最新文章

热门文章

Hot 文章

Python

C 语言

C++基础

大数据基础

linux编程基础

C/C++面试题目