您的位置:首页 > Web前端

SSH Warning: the RSA host key for differs from the key for the IP address

2011-10-20 09:21 525 查看
[hudson@sjbude183v .ssh]$ ssh soa@sjisbe381 ls /tmp

The authenticity of host 'sjisbe381 (10.100.87.11)' can't be established.

RSA key fingerprint is 8f:bd:9b:06:92:1d:0b:6e:0e:d0:f3:d1:cd:f7:f7:6e.

Are you sure you want to continue connecting (yes/no)?yes

Warning: Permanently added 'sjisbe381' (RSA) to the list of known hosts.

Warning: the RSA host key for 'sjisbe381' differs from the key for the IP address '10.100.87.11'

Offending key for IP in /builds/hudson/.ssh/known_hosts:36

Are you sure you want to continue connecting (yes/no)?


当ssh访问一台server时,如果出现“Warning: the RSA host key for differs from the key for the IP address”这样的信息,表示在known_hosts里已经有一台server和你正要访问的server的IP冲突。

另外一条类似于这样的信息“Offending key for IP in /builds/hudson/.ssh/known_hosts:36″,表示IP冲突位于known_hosts的第36行, 只要打开~/.ssh/known_hosts,删除第36行就可以将问题解决,或者直接运行一条命令搞定“sed -i -e ’36d’ ~/.ssh/known_hosts”。

如果你想彻底摆脱known_hosts,将“StrictHostKeyChecking no”添加到~/.ssh/config,这样以后访问新的server都不在有known_hosts的提示。
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐