SSH Too many authentication failures

When i ssh into a server, i get following error

I checked server log (/var/log/auth.log) and found following

This error happens when you have several SSH keys. When you try to connect to remote server, ssh client try to autenticate to remote server using SSH keys present on your computer. If you have several keys, ssh client make that much login attempts if the keys are valid for remote server you are trying to login.

ssh server deamon have a settings MaxAuthTries. Default value for this settings is 6. If number of invalid login attempt exceeds the value of MaxAuthTries, you will get above error.

You can see all SSH keys on your computer with

If you have many keys, consider removing some of the keys from agent using ssh-add command.

To fix this error edit file

Check if the file have entry for MaxAuthTries, if yes, increase its value. If no entry present in the server add it.

Restart sshd service.

You can see how many login attemts you make using ssh -v option (verbose).

See SSH

Need help with Linux Server or WordPress? We can help!

Leave a Reply

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