代码之家  ›  专栏  ›  技术社区  ›  Nikhil Das Nomula

AWS Ubuntu使用密码身份验证添加用户

  •  0
  • Nikhil Das Nomula  · 技术社区  · 8 年前

    我们怎么做

    sudo adduser deploy --home /home/deploy --shell /bin/bash
    

    但是当我在mac上运行以下命令时

    ssh deploy@<ip-address-of-aws-ubuntu-machine>
    

    它说权限被拒绝(公钥)

    1 回复  |  直到 8 年前
        1
  •  0
  •   Brandon Miller    8 年前

    当然有可能。我强烈建议对这个用户使用密钥身份验证,因为它更安全,但是如果您坚持使用密码,则必须在您的系统中启用密码身份验证 sshd_config 通常在 /etc/ssh/sshd_config . 更改此行:

    PasswordAuthentication no
    

    PasswordAuthentication yes