SSH ハードウェア交換後に怒られた場合

投稿者:

[admin@dokuo admin]$ ssh 192.168.1.9 -l admin
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
37:cd:20:39:85:5e:10:fe:3d:6c:b3:44:25:82:97:d5.
Please contact your system administrator.
Add correct host key in /home/admin/.ssh/known_hosts to get rid of this message.
Offending key in /home/admin/.ssh/known_hosts:2
RSA host key for 192.168.1.9 has changed and you have requested strict checking.
Host key verification failed.
[admin@dokuo admin]$ rm /home/admin/.ssh/known_hosts
[admin@dokuo admin]$ ssh 192.168.1.9 -l admin
The authenticity of host ‘192.168.1.9 (192.168.1.9)’ can’t be established.
RSA key fingerprint is 37:cd:20:39:85:5e:10:fe:3d:6c:b3:44:25:82:97:d5.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added ‘192.168.1.9’ (RSA) to the list of known hosts.
admin@192.168.1.9’s password:
Last login: Mon Nov 24 11:25:09 2008 from 192.168.1.7
[admin@localhost ~]$
ハード交換後にSSHログインしようとしたら怒られた。
おそらく「/home/admin/.ssh/known_hosts」に記録している過去のデータと今のハードのデータが合わなくて認証でけられてるみたい。
LANカードは同じだからMACではなさそう。
なので「/home/admin/.ssh/known_hosts」を削除したらちゃんとログインできた。

Thank you for reading this post, don't forget to subscribe!