2019-02-10  2024-09-18    174 字  1 分钟

在git bash链接远程主机时连接失败

 1@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
 2@    WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED!     @
 3@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
 4IT IS POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY!
 5Someone could be eavesdropping on you right now (man-in-the-middle attack)!
 6It is also possible that a host key has just been changed.
 7The fingerprint for the RSA key sent by the remote host is
 851:82:00:1c:7e:6f:ac:ac:de:f1:53:08:1c:7d:55:68.
 9Please contact your system administrator.
10Add correct host key in /Users/isaacalves/.ssh/known_hosts to get rid of this message.
11Offending RSA key in /Users/isaacalves/.ssh/known_hosts:12
12RSA host key for 104.131.16.158 has changed and you have requested strict checking.
13Host key verification failed.

这种情况下并非是远程主机配置出现问题,而是曾经连接过一次此主机,而此次连接时缓存密钥不匹配

1# 编辑此文件,删除缓存密钥即可
2vim ~/.ssh/known_hosts

除另有声明外本博客文章均采用 知识共享 (Creative Commons) 署名 4.0 国际许可协议 进行许可转载请注明原作者与文章出处