【问题标题】:SCP without asking "Continue or not"SCP没有问“继续与否”
【发布时间】:2014-06-05 17:36:28
【问题描述】:

我正在尝试使用 pem 密钥将一些文件 scp 到不同的计算机,所以我不需要我的密码。但是,每次我尝试连接到一个新盒子时,它都会问我“说真的,你想连接吗?你想保存密钥吗?......”这太烦人了,scp 中是否有一些标志如“ yum -y" 回答所有这些问题。

[user@commander tmp]$ scp -i mykey.pem target.txt ubuntu@xxx.xx.xx.xx:/commander
The authenticity of host 'xxx.xx.xx.xx (xxx.xx.xx.xx)' can't be established.
RSA key fingerprint is junk:junk:junk... many junks... goes here
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added 'xxx.xx.xx.xx' (RSA) to the list of known hosts.

谢谢!

【问题讨论】:

    标签: ubuntu scp


    【解决方案1】:

    是的,它有。 -o BatchMode=yes 是直接候选人。你也可以改变StrictHostKeyChecking(在描述的条件下看起来很安全)和UserKnownHostsFile。您可以在其联机帮助页上获得更多详细信息。

    【讨论】:

      猜你喜欢
      • 2011-07-01
      • 2015-02-11
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2010-09-07
      • 2019-07-31
      • 1970-01-01
      • 2014-01-18
      相关资源
      最近更新 更多