I have set up a new virtual server today, including PubKeyAuthentication and so on...
If I now want to connect to other servers via SSH the client always wants to connect to one I was mainly working with today - regardless the addresses and also regardless the terminal app that I'm using (I have tried Terminal and Tabby).
It kinda looks like this:
ssh [email protected]
the answer is
[email protected]: Permission denied (publickey).
Also if I try to connect to another server on Strato:
[email protected]
the answer is always
[email protected]: Permission denied (publickey).
Connecting to
ssh -i ~/.ssh/id_rsa -l user xxxxxxxx.stratoserver.net
works fine.
As mentioned it is regardless of the terminal app. I have also restarted my machine without any change.
The content of the ~/.ssh/config
is
User username
HostName xxxxxxxx.stratoserver.net
IdentityFile ~/.ssh/id_rsa
Host connectionname_x (username)
User username
HostName xxxxxxx.stratoserver.net
IdentityFile ~/.ssh/id_rsa
Host connectionname_y (root)
User root
HostName yyyyyyyy.stratoserver.net
Host connectionname_local
User root
HostName 192.168.178.34