This article is a mirror article of machine translation, please click here to jump to the original article.

View: 8752|Reply: 0

[Solved] Mysql connection error 'mysqladmin flush-hosts'

[Copy link]
Posted on 6/10/2019 10:41:06 AM | | |
Mistake:
A recent error was found in the logs as follows:Host is blocked because of many connection errors; unblock with 'mysqladmin flush-hosts'

Cause:
Baidu searched for the reason: the same IP generated too many interrupted database connections (exceeding the maximum value of mysql database max_connection_errors) in a short period of time.

Workaround:Increase the number of max_connection_errors allowed
Go to the Mysql database to view the max_connection_errors:
Option 1:The number of modified max_connection_errors is 1000
Or go directly to my.cnf to configure
Add under [mysqld]
Then restart mysql
You can then check if this parameter is in effect
Option 2:
Reset the number of error recordsGo to the database and execute the command
max_connect_errors If this parameter has not been set, the default max_connect_errors = 10, you can set the parameter a little larger to avoid being locked.
If you have a master/slave master-slave database, you need to modify both the master and slave databases.






Previous:Which god will share a single page html generator?
Next:Have you ever done IM instant messaging?
Disclaimer:
All software, programming materials or articles published by Code Farmer Network are only for learning and research purposes; The above content shall not be used for commercial or illegal purposes, otherwise, users shall bear all consequences. The information on this site comes from the Internet, and copyright disputes have nothing to do with this site. You must completely delete the above content from your computer within 24 hours of downloading. If you like the program, please support genuine software, purchase registration, and get better genuine services. If there is any infringement, please contact us by email.

Mail To:help@itsvse.com