ssh 首次连接时提示 yes/no

连接提示

  • 首次进行ssh链接时,出现以下提示

    1. The authenticity of host '192.168.100.1(192.168.100.1 )' can't be established. RSA key fingerprint is a0:00:d3:33:54:96:40:03:ff:ad:15:a9:59:22:f4:2a.
    2. Are you sure you want to continue connecting (yes/no)?
  • 批量连接时跳出这个提示很麻烦,可以通过以下方法禁止提示,直接允许。

    相关配置

  • 创建文件 /root/.ssh/config,添加一行:

    1. echo "StrictHostKeyChecking no" >> /root/.ssh/config
  • 再使用ssh连接其他机器就不再跳了。