问题:当第一次连接服务器(ssh -X nvidia@192.168.1.113)时会出现如下打印信息:
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@ WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED! @
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
IT IS POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY!
Someone could be eavesdropping on you right now (man-in-the-middle attack)!
It is also possible that a host key has just been changed.
The fingerprint for the ECDSA key sent by the remote host is
SHA256:FGBLd5bBbU2BeLc6ft20WFKAdMOPK1k6mYIE1i5UZiw.
Please contact your system administrator.
Add correct host key in /home/idriver/.ssh/known_hosts to get rid of this message.
Offending ECDSA key in /home/idriver/.ssh/known_hosts:6
remove with:
ssh-keygen -f "/home/idriver/.ssh/known_hosts" -R 192.168.1.112
ECDSA host key for 192.168.1.112 has changed and you have requested strict checking.
Host key verification failed.
原因:第一次连接ssh时候 会生成一个认证,存储客户端中的know_hosts,如果服务器地址重置或者刷新系统,就会出现以上错误打印信息。
解决方法:ssh-keygen -R 192.168.1.113
然后重新连接,如下图所示:
登陆成功: