MySQL databaseSome exceptions may occur during operations. It is better to try to log on as unverified users as described below, that is, problems that may occur during MySQL database operations, the following sections describe in detail.
Today, the company's database encountered a pause and blocking problem. When checking the database, we found that the show processlist; can see a large number:
....
: 3436942: unauthenticated user: 192.168.0.4: 49607: Connect: login:
: 3436943: unauthenticated user: 192.168.0.4: 49608: Connect: login:
.....
Some unverified users tried to log on but failed to log on. Some Google users found that they had something to do with domain name resolution:
No matter what client connection comes up, the server will perform DNS lookup on the client to obtain the client's domain name or host name.
It is very likely that the DNS server has a problem and thus cannot be resolved-although the parsed result should be none
Add skip-name-resolve to my. cnf
To disable Reverse Domain name resolution or add the parameter -- skip-name-resolve in the startup command line.
This method is also one of the recommended MySQL optimization methods.
However, the disadvantage of this method is that the host in the permission cannot use the host name, but the IP address is used. Fortunately, we configured "%", so I prefer to use another method, add the corresponding host record to the/etc/hosts file.
I believe that through the above study, you can easily solve similar problems in your future work. I hope you will all be able to gain some benefits from the content mentioned above.