Segurament us heu trobat amb el seguent missatge al intentar accedir a un servidor :
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@ 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
2c:26:8a:dd:91:9f:09:ed:a3:79:36:79:74:c1:9b:ff.
Please contact your system administrator.
Add correct host key in /home/david/.ssh/known_hosts to get rid of this message.
Offending key in /home/david/.ssh/known_hosts:8
RSA host key for 10.139.162.10 has changed and you have requested strict checking.
Host key verification failed.
La solució es remoure la key del servidor en qüestió….
Remove keys
Fer servir la opció -R per treure totes les keys del hostname del know_hosts.
$ ssh-keygen -R {server.name.com}
$ ssh-keygen -R {ssh.server.ip.address}
$ ssh-keygen -R server.example.com
Salut !!