Connecting to SSH server slow since macOS upgrade

ssh

Since upgrading to macOS I have had problems with slow connection to my local server running Debian.

Running ssh -v shows that it is hanging at the following message.

debug1: SSH2_MSG_SERVICE_ACCEPT received

A search has said try to enable the NoDNS option within the servers sshd config but that has not helped.

Has anyone got any ideas?

Best Answer

I tracked down my slow SSH logins to IPv6 timeouts. This was from a Sierra client to a Sierra server. After adding the following to my client ~/.ssh/config it is now near instantaneous.

# Default is 'any' which includes inet6
AddressFamily inet