ssh ec2密钥错误权限被拒绝(公钥)

时间:2020-02-02 17:35:59

标签: amazon-web-services amazon-ec2 ssh amazon-ami

我正在使用以下步骤:

  1. 我有一个通过AMI Ubuntu 16.04运行的实例。
  2. 停止实例
  3. 创建AMI映像
  4. 与另一个帐户共享。
  5. 从此AMI创建实例并启动它。
  6. 启动时,当我与ssh连接时,它给出了错误。 AMI操作系统已将Ubuntu更改为其他Linux。
$ ssh -i "z2pSandBox.pem" ubuntu@ec2-13-233-53-125.ap-south-1.compute.amazonaws.com
    The authenticity of host 'ec2-13-233-53-125.ap-south-1.compute.amazonaws.com (13.233.53.125)' can't be established.
    ECDSA key fingerprint is SHA256:vcNjY+sDkCLxtoAPwJXUqOqZnYWxm+fzoRC7uyC+D6s.
    Are you sure you want to continue connecting (yes/no)? yes
    Warning: Permanently added 'ec2-13-233-53-125.ap-south-1.compute.amazonaws.com,13.233.53.125' (ECDSA) to the list of known hosts.
    ubuntu@ec2-13-233-53-125.ap-south-1.compute.amazonaws.com: Permission denied (publickey).

0 个答案:

没有答案