vi /etc/ssh/ssh_config(全局)

或者

~/.ssh/config(某用户)

开头加入以下内容:

StrictHostKeyChecking no

然后重启ssh

service sshd reload