Questions? Feedback? powered by Olark live chat software
Knowledgebase
Author Avatar

SSH Session Slow to Authenticate - Fix

Written by: on 27 May 2016 04:09 PM 27 May 2016 04:09 PM

Waiting too longer to log into your VPS with ssh for the session to authenticate? Fix this issue by follow our easy tips.

If you are trying to log into your VPS with ssh and found you have to wait much longer than reasonable for the session to authenticate, the issue lies with a hostname lookup.

Essentially the session is slow because the SSH server is trying to lookup the hostname of the SSH client in DNS. This may not exist, and takes some time to do a reverse DNS lookup.

There are a couple of very simple ways to fix that:

  • add "UseDNS no" to /etc/ssh/sshd_config (recommended)
  • add the client's net address to the server's /etc/hosts
(0 vote(s))
Helpful
Not helpful