When connecting to a host that expects key authentication, which key (if any) will be tried if there is no key found under the path
~/.ssh/id_rsa* when using ssh client from commandline in linux?
There are also tried keys provided by running
ssh-agent (added by
ssh-add) and the keys explicitly mentioned in configuration files as
If none of them applies, then the authentication using publickey fails and usually falls back to password authentication. If password authentication is not allowed (on server or on client), the whole authentication fails.