【问题标题】:Unable to connect to amazon ec2 ubuntu instance via ssh using elastic ip无法使用弹性 ip 通过 ssh 连接到亚马逊 ec2 ubuntu 实例
【发布时间】:2019-03-27 13:21:42
【问题描述】:

起初,我可以使用 ssh 进行连接。 一段时间后,连接关闭,从那以后我无法连接。 下面是调试日志。 我可以看到连接已建立但再次中断。

我已尝试重新启动、启动和停止服务器,但对我没有任何效果。请帮忙。

username:coding my.name$ ssh -i "aws_ubuntu_16.pem" ubuntu@xx.xx.xx.xx -vv
OpenSSH_7.7p1, LibreSSL 2.7.3
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 48: Applying options for *
debug2: resolve_canonicalize: hostname xx.xx.xx.xx is address
debug2: ssh_connect_direct: needpriv 0
debug1: Connecting to xx.xx.xx.xx [xx.xx.xx.xx] port 22.
debug1: Connection established.
debug1: key_load_public: No such file or directory
debug1: identity file aws_ubuntu_16.pem type -1
debug1: key_load_public: No such file or directory
debug1: identity file aws_ubuntu_16.pem-cert type -1
debug1: Local version string SSH-2.0-OpenSSH_7.7
ssh_exchange_identification: read: Connection reset by peer

【问题讨论】:

    标签: amazon-ec2 ssh


    【解决方案1】:
    • 方法 1:此问题最可能的原因是 您的 IP 必须已被列入黑名单。你能检查一下 您的弹性 IP 被列入黑名单。如果是,将其列入白名单并尝试 ssh 再次。您可以使用'spamhaus.org'来检查黑名单 IP 并再次将其列入白名单。
    • 方法2:不推荐,但可以尝试更改弹性IP 如果问题仍然存在。

    【讨论】:

      猜你喜欢
      • 2016-01-12
      • 2012-08-19
      • 2018-04-17
      • 2011-08-12
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2011-07-05
      • 2016-04-27
      相关资源
      最近更新 更多