Solution: authentication takes too long during ssh connection
I used Xshell for my work, but I found that it took about 10 seconds to wait for Xshell to connect to a remote host in the last few days. I used to connect to the remote host and checked it online, the solution is simple. You only need to change the dns authentication in the/etc/ssh/sshd_config file to no, that is, change # UseDns yes to UseDns no to OK. Restart the ssh service: sudo service sshd restart. At this time, when you reconnect to Xshell, you will find that there is almost no waiting time.
Note: UseDns is used to specify whether reverse resolution should be performed on the remote host name to check whether the host name actually corresponds to its IP address. The default value is "yes ".
For more information about the configurations of sshd_config, see: http://blog.csdn.net/zhu_xun/article/details/18304441