跳板机只有一个 两个服务器群组 一个组用key1 跳板机无密码登录一直没问题 加入组2服务器后使用另外一个key2 现在必须使用ssh -i keyfile user@ip
登录
update 2019年4月11日
一个“取巧”的方法 来自stackoverflow~/.ssh/config
开头添加N行IdentityFile ~/.ssh/{key_filename}
比如IdentityFile ~/.ssh/id_rsa IdentityFile ~/.ssh/id_rsa_old IdentityFile ~/.ssh/id_ed25519
ssh 将如下
debug1: Trying private key: /home/example/.ssh/id_rsa debug1: read PEM private key done: type RSA debug1: Authentications that can continue: publickey debug1: Trying private key: /home/example/.ssh/id_rsa_old
一个链接解决所有问题
https://linux.die.net/man/5/s...