Host key verification failed的解决方法

2018/12/7 posted in  记录

@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
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 the RSA host key has just been changed.
The fingerprint for the RSA key sent by the remote host is
5c:9b:16:56:a6:cd:11:10:3a:cd:1b:a2:91:cd:e5:1c.
Please contact your system administrator.
Add correct host key in /Users/user/.ssh/known_hosts to get rid of this message.
Offending key in /Users/user/.ssh/known_hosts:1
RSA host key for server1.example.com has changed and you have requested strict checking.
Host key verification failed.

这是我昨晚在连接一台本来已经放弃了的AlphaRacks的VPS的时候 Terminal终端给的报错信息
应该是我在后端重装了VPS系统之后,导致SSH公钥变化,所以之后才会出现这个报错

解决的方法也很简单
ssh-keygen -R server-name
ssh-keygen -R server.ip.addre.ss
ssh-keygen -R 202.54.1.5
ssh-keygen -R server1.example.com

刚才又重装了一遍VPS的系统 在terminal里又走了一遍这个方法 验证下来应该是没有问题的

不过为什么AlphaRacks在
http://ping.pe 的ping值还不至于很难看的情况下

只要是装 https://teddysun.com/486.html 的一键脚本就会根本用不了呢




打赏 | Buy me a coffee

dashang