【问题标题】:Cannot connect to my aws ec2 instance无法连接到我的 aws ec2 实例
【发布时间】:2015-10-19 11:00:56
【问题描述】:

我面临“ssh_exchange_identification: read: Connection reset by peer”错误。我之前的会话异常关闭。现在我无法连接到我的实例。

非常感谢任何帮助。谢谢你。

下面是调试信息

ssh -i "aws/githubapi.pem" ubuntu@52.26.94.220 -vv

OpenSSH_6.6.1, OpenSSL 1.0.1f 6 Jan 2014
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: Applying options for *
debug2: ssh_connect: needpriv 0
debug1: Connecting to 52.26.94.220 http://52.26.94.220 port 22.
debug1: Connection established.
debug1: identity file aws/githubapi.pem type -1
debug1: identity file aws/githubapi.pem-cert type -1
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_6.6.1p1 Ubuntu-2ubuntu2
ssh_exchange_identification: read: Connection reset by peer

更多信息:

ssh -v ubuntu@54.148.82.122

OpenSSH_6.6.1, OpenSSL 1.0.1f 6 Jan 2014
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: Applying options for *
debug1: Connecting to 54.148.82.122 [54.148.82.122] port 22.
debug1: Connection established.
debug1: identity file /home/moiz/.ssh/id_rsa type -1
debug1: identity file /home/moiz/.ssh/id_rsa-cert type -1
debug1: identity file /home/moiz/.ssh/id_dsa type -1
debug1: identity file /home/moiz/.ssh/id_dsa-cert type -1
debug1: identity file /home/moiz/.ssh/id_ecdsa type -1
debug1: identity file /home/moiz/.ssh/id_ecdsa-cert type -1
debug1: identity file /home/moiz/.ssh/id_ed25519 type -1
debug1: identity file /home/moiz/.ssh/id_ed25519-cert type -1
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_6.6.1p1 Ubuntu-2ubuntu2
ssh_exchange_identification: read: Connection reset by peer

【问题讨论】:

  • 您是否对 sshd 配置进行了任何更改或删除了 .ssh 文件夹中的任何内容。如果无法访问,请重新启动机器并重试。
  • @AmalGJose 是的,我已经编辑了 sshd_config 文件,但现在我已将其恢复,重新启动本地和远程计算机。还是不行。

标签: linux amazon-web-services ssh amazon-ec2 ssh-keys


【解决方案1】:

我的 Intranet 防火墙阻止我发送 ssh 请求。

【讨论】:

    猜你喜欢
    • 2018-01-03
    • 2016-08-24
    • 1970-01-01
    • 2021-07-18
    • 2016-09-22
    • 2015-12-28
    • 2012-12-26
    • 2021-12-18
    • 2014-03-03
    相关资源
    最近更新 更多