This article from: http://forum.ubuntu.org.cn/viewtopic.php? F = 54 & t = 177845
Friends who often use Ubuntu can get used to the fact that
That is, it takes more than 10 seconds or even more than 20 seconds to log on to Ubuntu through SSH. You may be used to this fact, but, in fact, this long wait time can be avoided. How can this problem be avoided, follow the steps below to disable SSH gssapi authentication VI/etc/ssh/ssh_config and comment out the following two lines: gssapiauthentication yesgssapidelegatecredentials no step 2 disable SSH usednsvi/etc/ssh/sshd_config. Note: the sshd_config file of ubuntu does not have the usedns parameter. As far as I know, the sshd_config of * nix and * BSD operating systems all have usedns parameters, and the default values are "usedns yes ", it is estimated that although the Ubuntu sshd_config does not have usedns, it is also "usedns yes" by default. Therefore, insert the following line at the end of sshd_config: US Edns no and then execute the command "/etc/init. d/ssh restart ", restart the SSH service, and the configuration takes effect after testing. After using this method, the Ubuntu authentication time is greatly shortened, in the past, the login authentication generally took about 15 seconds over 10 seconds. In some cases, it even took about 20 seconds to 30 seconds, the login authentication time for Ubuntu will be shortened to less than 3 seconds.