首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >如何解决此错误: ssh_exchange_identification:远程主机关闭的连接

如何解决此错误: ssh_exchange_identification:远程主机关闭的连接
EN

Server Fault用户
提问于 2012-11-13 06:12:58
回答 3查看 2.1K关注 0票数 1
代码语言:javascript
复制
data@server01:~$ ssh user@10.7.4.1 -vvv
OpenSSH_5.5p1 Debian-6, OpenSSL 0.9.8o 01 Jun 2010
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: Applying options for *
debug2: ssh_connect: needpriv 0
debug1: Connecting to 10.7.4.1 [10.7.4.1] port 22.
debug1: Connection established.
debug3: Not a RSA1 key file /home/data/.ssh/id_rsa.
debug2: key_type_from_name: unknown key type '-----BEGIN'
debug3: key_read: missing keytype
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug2: key_type_from_name: unknown key type '-----END'
debug3: key_read: missing keytype
debug1: identity file /home/data/.ssh/id_rsa type 1
debug1: Checking blacklist file /usr/share/ssh/blacklist.RSA-2048
debug1: Checking blacklist file /etc/ssh/blacklist.RSA-2048
debug1: identity file /home/data/.ssh/id_rsa-cert type -1
debug1: identity file /home/data/.ssh/id_dsa type -1
debug1: identity file /home/data/.ssh/id_dsa-cert type -1
ssh_exchange_identification: Connection closed by remote host
EN

回答 3

Server Fault用户

发布于 2012-11-13 08:37:31

我怀疑你的私钥出了什么问题,可能是第一行。

不要把它粘贴到问题中。

你是怎么生成私钥的?你能试着创造一个新的吗?(请记住,它们是成对的,所以只有在您也可以在另一端更改公钥的情况下才会这样做。)

票数 1
EN

Server Fault用户

发布于 2012-11-13 09:51:07

密钥很可能是SSL或PuTTY格式的。它与Linux客户机/服务器不兼容。

票数 0
EN

Server Fault用户

发布于 2012-11-14 12:44:03

是的,这是格式-看上去像一个肉酱生成的钥匙。

若要正确剪切/粘贴puttygen键,请参见此处:http://www.howtoforge.com/how-to-configure-ssh-keys-authentication-with-putty-and-linux-server-in-5-quick-steps

但是--你不是从Windows电脑上跳出来的,是吗?看起来你从一个基于Debian的服务器变成了一个私有IP。你想在另一个主机上使用puttygen键吗?为什么这样做而不是'ssh-keygen'?

我很好奇你在这里想做什么。你能给出更多细节吗?

票数 0
EN
页面原文内容由Server Fault提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://serverfault.com/questions/448087

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档