Slow logon to sshmysql over the intranet: bitsCN.com
The development environment of a company is usually deployed on the intranet, and then there will be public servers for developers and tests. Therefore, there is often a need to connect to the server through ssh or a local mysql client, in my personal experience, companies often encounter slow ssh/mysql connection to public servers. this is because ssh and mysql services use reverse DNS resolution at login by default, the intranet is usually not equipped with DNS services, so we can only wait for these services to time out before allowing us to log on through. the solution is also very simple, you only need to disable the resolution of the corresponding service.
The first is ssh, as follows:
/Etc/ssh/sshd_config
UseDNS no
GSSAPIAuthentication no
GSSAPICleanupCredentials yes
Followed by the mysql service:
/Etc/my. ini
[Mysqld]
Skip-name-resolve
Skip-grant-tables
That's all. restart our ssh and mysql services and connect to ssh/mysql again quickly.
Of course, we still need to enable these security mechanisms for online machines.
BitsCN.com