To fix delay in SSH Login

If you found this post helpful, kindly share it and show your support :)

DNS lookup query is responsible for the delay because SSH wait for a response of reverse DNS lookup query that is been made to DNS Server.

Solution :

To overcome this issue, please follow these steps:

  • Edit  /etc/ssh/sshd_config  on sshd  Server
vi /etc/ssh/sshd_config

and add following DNS option to the file:

UseDNS no

save  and exit

  • Add the following line to your /etc/resolv.conf file.
options single-request-reopen
  • Restart  sshd  service
 /etc/init.d/sshd  restart

That’s it 🙂

Loading

Mohammed Noufal

I'm Mohammed Noufal, working as Server Admin for the last 10 years.  In my day-to-day life, l had to face different problems related to Web-hosting. On my website Errorlogz.com, you can find solutions for different Web-hosting-related problems. Sometimes, I spent hours searching/googling to find a solution. This inspired me to start a website that gives solutions to different Webhosting problems. This website includes basic Linux and windows commands, and different control panels like cPanel, Plesk, DirectAdmin, Webmin & so on. You can find solutions and or suggestions for different Web-hosting related problems from here. Hence I would like to say Errorlogz is your server protector.  I will be glad if Logdetect can help any one of the Server admins to find a solution to his problem.

You may also like...

Leave a Reply

Your email address will not be published. Required fields are marked *