当前位置:网站首页>Frequent MySQL operations cause table locking problems
Frequent MySQL operations cause table locking problems
2022-07-05 20:22:00 【Mountain King in kindergarten】
One 、 Error reporting
org.springframework.dao.CannotAcquireLockException:
### Error updating database. Cause: com.mysql.cj.jdbc.exceptions.MySQLTransactionRollbackException: Lock wait timeout exceeded; try restarting transaction
This error is due to the frequent operation of threads or other operations mysql The database caused the table to be locked .
Two 、 Solution
1、 Execute the following statement in the database .
SELECT * FROM INFORMATION_SCHEMA.INNODB_TRX;
There will be
2、 And then find trx_mysql_thread_id Column
Use kill id; Delete the corresponding thread id Can solve .
边栏推荐
- model方法
- 实操演示:产研团队如何高效构建需求工作流?
- . Net distributed transaction and landing solution
- BZOJ 3747 POI2015 Kinoman 段树
- Oracle-表空间管理
- How to retrieve the root password of MySQL if you forget it
- About the priority of Bram IP reset
- ROS2专题【01】:win10上安装ROS2
- sun. misc. Base64encoder error reporting solution [easy to understand]
- Rainbow 5.7.1 supports docking with multiple public clouds and clusters for abnormal alarms
猜你喜欢
Rainbow 5.7.1 supports docking with multiple public clouds and clusters for abnormal alarms
[quick start to digital IC Verification] 8. Typical circuits in digital ICs and their corresponding Verilog description methods
Ros2 topic [01]: installing ros2 on win10
Oracle tablespace management
618 "low key" curtain call, how can baiqiushangmei join hands with the brand to cross the "uncertain era"?
[quick start of Digital IC Verification] 7. Basic knowledge of digital circuits necessary for verification positions (including common interview questions)
Introduction to dead letter queue (two consumers, one producer)
How to select the Block Editor? Impression notes verse, notation, flowus
leetcode刷题:二叉树10(完全二叉树的节点个数)
Leetcode skimming: binary tree 16 (path sum)
随机推荐
Database logic processing function
Scala基础【HelloWorld代码解析,变量和标识符】
14、Transformer--VIT TNT BETR
[C language] merge sort
[quick start of Digital IC Verification] 1. Talk about Digital IC Verification, understand the contents of the column, and clarify the learning objectives
Leetcode brush questions: binary tree 18 (largest binary tree)
CTF reverse Foundation
本季度干货导航 | 2022年Q2
A way to calculate LNX
Leetcode (347) - top k high frequency elements
2020 CCPC 威海 - A. Golden Spirit(思维),D. ABC Conjecture(大数分解 / 思维)
E. Singhal and Numbers(质因数分解)
What is PyC file
sun.misc.BASE64Encoder报错解决方法[通俗易懂]
【数字IC验证快速入门】9、Verilog RTL设计必会的有限状态机(FSM)
Scala basics [HelloWorld code parsing, variables and identifiers]
解决php无法将string转换为json的办法
小程序事件绑定
Leetcode (695) - the largest area of an island
Minimum commission for stock trading account opening, where to open an account with low commission? Is it safe to open an account on your mobile phone