Ansible won't connect via SSH

Your -vvv output shows that Ansible is run with the parameter -o ConnectTimeout=10.

There are several reasons that could result in a time longer than 10 seconds for an SSH connection, for example the SSH server trying to look up the hostname of the connecting client is a common culprit that takes some time.

Check the time it takes when you connect your SSH session manually, if it takes too long you have two possibilities:

  • check what takes so long and resolve that issue
  • increase the ConnectTimeout value for your Ansible setup

The first solution should be the preferred one.