mysql 1205 ,自动重启数据库

2017-06-15 14:44:30 +08:00
 huangmm

最近 mysql 从库老是发生错误然后自动重启数据库,比如以下错误: 2017-06-11T10:09:59.977948+08:00 1 [Note] Slave I/O thread killed while reading event for channel '' 2017-06-11T10:09:59.977983+08:00 1 [Note] Slave I/O thread exiting for channel '', read up to log 'mysql-bin.000618', position 749877680 2017-06-11T10:09:59.992965+08:00 0 [Note] Giving 16 client threads a chance to die gracefully 2017-06-11T10:09:59.993028+08:00 0 [Note] Shutting down slave threads 2017-06-11T10:09:59.994228+08:00 2 [Note] Error reading relay log event for channel '': slave SQL thread was killed 2017-06-11T10:10:02.013081+08:00 0 [Note] Forcefully disconnecting 3 remaining clients 。。。。。。

第二种 2017-06-15T11:11:55.948857+08:00 267503 [Warning] Slave SQL for channel '': Worker 0 failed executing transaction 'ANONYMOUS' at master log mysql-bin.000686, end_log_pos 211890878; Could not execute Write_rows event on table sks_lexiangquan.sks_tao_rebate; Lock wait timeout exceeded; try restarting transaction, Error_code: 1205; handler error HA_ERR_LOCK_WAIT_TIMEOUT; the event's master log mysql-bin.000686, end_log_pos 211890878, Error_code: 1205 03:11:56 UTC - mysqld got signal 11 ; This could be because you hit a bug. It is also possible that this binary or one of the libraries it was linked against is corrupt, improperly built, or misconfigured. This error can also be caused by malfunctioning hardware. Attempting to collect some information that could help diagnose the problem. As this is a crash and something is definitely wrong, the information collection process might fail.

key_buffer_size=8388608 。。。。。

然后就自动重启了数据库,释放了内存 重启之后主从自动恢复 但是对线上查询业务有影响,求解惑,已经加大 innodb_lock_wait_timeout 问题是另外还有两台从库却没有出现这种情况,对比了一下相关的参数配置并没有什么不同

1327 次点击
所在节点    问与答
2 条回复
huangmm
2017-06-16 10:10:58 +08:00
第一个是没有报错的自动重启,内存都很正常,是否是分配给 mysql 的资源被用光?
LevineChen
2017-06-20 14:11:49 +08:00
不懂 帮顶

这是一个专为移动设备优化的页面(即为了让你能够在 Google 搜索结果里秒开这个页面),如果你希望参与 V2EX 社区的讨论,你可以继续到 V2EX 上打开本讨论主题的完整版本。

https://www.v2ex.com/t/368610

V2EX 是创意工作者们的社区,是一个分享自己正在做的有趣事物、交流想法,可以遇见新朋友甚至新机会的地方。

V2EX is a community of developers, designers and creative people.

© 2021 V2EX