Lock wait timeout exceeded; try restarting transaction
程序员文章站
2024-01-12 16:25:34
...
在更新一条数据时,前端页面一直加载转圈,之后后台报错
Lock wait timeout exceeded; try restarting transaction
解决办法:
select * from information_schema.INNODB_TRX;
找到trx_mysql_thread_id对应的值:如13336,之后结束该进程
kill 13336
也可以增加锁等待时间
SHOW VARIABLES LIKE ‘innodb_lock_wait_timeout’;
set innodb_lock_wait_timeout=100;
推荐阅读
-
Lock wait timeout exceeded; try restarting transaction
-
Lock wait timeout exceeded; try restarting transaction
-
Lock wait timeout exceeded; try restarting transaction
-
Mysql出现“ Lock wait timeout exceeded; try restarting trans
-
mysql报错:Deadlock found when trying to get lock; try restarting transaction的解决方法
-
数据库死锁的问题,Deadlock found when trying to get lock; try restarting transaction at Query.formatError
-
Lock wait timeout exceeded
-
Lock wait timeout exceeded; try restarting transaction
-
Mysql出现“ Lock wait timeout exceeded; try restarting trans
-
mysql提示 Lock wait timeout exceeded解决办法