错误描述:
Host is blocked because of many connection errors; unblock with 'mysqladmin flush-hosts'
环境:
linux,mysql5.5.21、
原因:
从某个客户端发起的数据库连接错误次数超过了max_connection_errors的设置值
解决办法:
【注意】如果是主从关系,需要在主从上分别执行
mysqladmin flush-hosts -h -P -uroot -p 或者登录mysql后执行flush host
show variables like '%max_connection_errors%';
set global max_connect_errors = 1000;并修改my.cnf配置文件
本文介绍了解决MySQL中因过多连接错误导致主机被封锁的问题。详细解释了如何通过执行mysqladmin flush-hosts命令或使用flush host命令来解决此问题,并调整max_connection_errors参数以避免未来发生类似情况。

被折叠的 条评论
为什么被折叠?



