MySql 在 Ubuntu 服务器“读取授权包"上崩溃 [英] MySql crashing on Ubuntu Server 'reading authorization packet'

查看:46
本文介绍了MySql 在 Ubuntu 服务器“读取授权包"上崩溃的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一台运行 Ubuntu 12.10 和 mysql 5.5 的服务器.这是主数据库服务器,上面没有运行其他任何东西.我使用了 2 个网站(都相当高流量).

I have a server running Ubuntu 12.10 and mysql 5.5. This is the primary database server and has nothing else running on it. 2 websites I have use it (both fairly high traffic).

前几天mysql服务宕机了.我没有遇到任何错误,它只是在我重新启动服务 service mysql restart 之前无法连接.

The mysql service went down the other day. I got no errors, it just wouldn't connect until I restarted the service service mysql restart.

在那之后一切都很好,直到今天早上 5 点.

Everything was fine after that until this morning at 5am.

Mysql 服务再次宕机,这次出现错误

Mysql service went down again, this time with the error

SQLSTATE[HY000] [2013] Lost connection to MySQL server at 'reading authorization packet', system error: 0

所以我重新启动了服务,它又好了.

So I restarted the service and it was fine again.

我已阅读文档,它说将 connect_timeout 全局变量增加到 10.已经是 10,所以我将其增加到 30.

I have read the docs and it says to increase the connect_timeout global variable to 10. It was already on 10 so I increased it to 30.

然后 5 小时后它再次关闭并出现与上述相同的错误.

Then 5 hours later it is down again with the same error as above.

在我放弃使用 PaaS 之前,有人有什么建议吗?

Anyone have any advice before I give up and use a PaaS?

推荐答案

这个旧的错误日志报告了许多人遇到同样的错误:错误 #28359 因读取授权包"错误而中断连接丢失.

This old bug log reports many people experiencing the same error: Bug #28359 Intermitted lost connection at 'reading authorization packet' errors.

MySQL 建议增加 connect_timeout 然后他们关闭了错误,尽管许多人继续报告针对许多版本的 MySQL 的错误,即使将 connect_timeout 增加到一个更大的值,最多 240 秒.

MySQL recommended to increase connect_timeout and then they closed the bug, despite many people continuing to report the error against many versions of MySQL, even when connect_timeout was increased to a much larger value, up to 240 seconds.

在错误日志和其他地方的报告中有一些模式:

There are some patterns among the reports in the bug log and elsewhere:

  • 当网络流量很高时,错误发生得更多.其他繁重的流量(如大型 rsync)可能会导致网络数据包校验和失败.增加网络带宽似乎有所帮助.

  • Error occurs more when the network traffic is high. Other heavy traffic (like a big rsync) may cause network packet checksums to fail. Increasing network bandwidth seems to help.

通过设置 skip-name-resolve 配置选项减少 DNS 流量被报告在一种情况下有所帮助.

Decreasing DNS traffic by setting skip-name-resolve config option was reported to help in one case.

几个报告说使用 bind_address=127.0.0.1 的网站出现故障,当他们取消该限制时,错误消失了.也许暗示环回以太网驱动程序有问题?我在这里推测.

Several reports that sites using bind_address=127.0.0.1 had failures, and when they removed that restriction, the errors vanished. Perhaps suggesting a fault in the loopback ethernet driver? I'm speculating here.

这篇关于MySql 在 Ubuntu 服务器“读取授权包"上崩溃的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆