mysqladmin flush-hosts

2018-06-19  本文已影响24人  DimonHo

异常现象:

(1129, "Host '192.168.1.61' is blocked because of many connection errors; unblock with 'mysqladmin flush-hosts'")

异常原因:

同一个ip在短时间内产生太多(超过mysql数据库max_connection_errors的最大值)中断的数据库连接而导致的阻塞;

解决方案:

show variables like '%max_connection_errors%';
set global max_connect_errors = 1000;

或者在my.cnf中配置

max_connect_errors = 1000
mysql> flush hosts;
上一篇 下一篇

猜你喜欢

热点阅读