报错信息:Host key verification failed.
$ ssh root@xx.xx.xx.xx
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@ 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.
Please contact your system administrator.
Add correct host key in /c/Users/helenlv/.ssh/known_hosts to get rid of this message.
Offending ECDSA key in /c/Users/helenlv/.ssh/known_hosts:9
ECDSA host key for xx.xx.xx.xx has changed and you have requested strict checking.
Host key verification failed.
解决方法
打开本机的 C:\Users\helenlv.ssh\known_hosts文件,删除有IP: xx.xx.xx.xx
的那一行,重新ssh即可

本文解决了一个常见的SSH远程登录问题,当遇到Hostkeyverificationfailed错误时,可以通过删除known_hosts文件中对应IP的主机密钥行来解决。此问题可能是由于主机密钥更改或中间人攻击引起。
19万+

被折叠的 条评论
为什么被折叠?



