连接在cygwin中被:: 1错误关闭 [英] Connection closed by ::1 error in cygwin

查看:140
本文介绍了连接在cygwin中被:: 1错误关闭的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想使用cygwin做ssh连接。我已遵循此处的说明。当我触发 ssh localhost 命令时,我得到连接关闭:: 1 错误。由于我是新手unix和cygwin,我不能弄清楚出了什么问题。

I am trying to do ssh connection using cygwin. I have followed instructions given here. When I fire ssh localhost command I get Connection closed by ::1 error. As I am newbie to unix and cygwin, I am not able to figure out what has gone wrong. Please can anyone tell me why this error comes and how to resolve it?

我的cygwin shell看起来如下:

My cygwin shell looks as follows :

$ ssh-keygen
Generating public/private rsa key pair.
Enter file in which to save the key (/home/Shekhar/.ssh/id_rsa):
/home/Shekhar/.ssh/id_rsa already exists.
Overwrite (y/n)? y
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in /home/Shekhar/.ssh/id_rsa.
Your public key has been saved in /home/Shekhar/.ssh/id_rsa.pub.
The key fingerprint is:
85:69:77:cc:fd:21:8a:ce:fe:46:41:ee:c8:e7:3d:7b Shekhar@Shekhar-PC
The key's randomart image is:
+--[ RSA 2048]----+
|                 |
|         o + .   |
|        + = +... |
|       . o.+. ...|
|        S.o..   .|
|        oo +     |
|         o+ .    |
|        .  o o E |
|         .o. .+  |
+-----------------+

Shekhar@Shekhar-PC ~
$ cd ~/.ssh/

Shekhar@Shekhar-PC ~/.ssh
$ ls -l
total 10
-rw-r--r-- 1 Shekhar None 1200 Jun 16 19:49 authorized_keys
-rw------- 1 Shekhar None 1675 Jun 20 08:55 id_rsa
-rw-r--r-- 1 Shekhar None  400 Jun 20 08:55 id_rsa.pub
-rw-r--r-- 1 Shekhar None  171 Jun  6 23:28 known_hosts

Shekhar@Shekhar-PC ~/.ssh
$ cat id_rsa.pub >> authorized_keys

Shekhar@Shekhar-PC ~/.ssh
$ ssh localhost
Connection closed by ::1


推荐答案

我的问题解决了。我刚刚删除了cygwin并重新安装它,它在某种程度上现在正常工作。

My problem is solved. I just removed cygwin and re-installed it and somehow its working properly now.

这篇关于连接在cygwin中被:: 1错误关闭的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆