代码之家  ›  专栏  ›  技术社区  ›  eswues

ssh配置主机限制

  •  2
  • eswues  · 技术社区  · 8 年前

    我有一些问题 ~/.ssh/config. 我有300台主机,需要以root而不是我的身份登录。

    host *
        user me
    host <here 300 hostnames seperated by space and in this same line all>
        user root
    

    wc -l .ssh/config
    

    给我4分

    1 回复  |  直到 8 年前
        1
  •  4
  •   Jakuje    8 年前

    当前OpenSSH的读数应高达 4096 字节长的行。但是OpenSSH 7.5之前的版本只能读取1024字节,这可能还不够( commit

    • 更新至OpenSSH 7.5
    • host <here first 100 hostnames seperated by space and in this same line all>
              user root
          host <here another 100 hostnames ...>
              user root
          host <here another 100 hostnames ...>
              user root