无法创建目录' //。ssh':没有此类文件或目录

时间:2015-10-06 17:25:11

标签: ssh ssh-keys sshd

我在我的Windows机器上运行SSHD,我是从http://www.apache.org/dyn/closer.cgi下载的

我能够运行SSHD,但每当我尝试从同一台机器连接时,都会出现以下错误。

C:\Users\fk>ssh fk1@localhost -p 8000
Password authentication
Password:
Password authentication
Password:
Password authentication
Password:
fk1@localhost's password:
Permission denied, please try again.
fk1@localhost's password:
Permission denied, please try again.
fk1@localhost's password:
Permission denied (password,keyboard-interactive,publickey).

我觉得它与没有publickey有关,所以我尝试通过运行ssh-keygen来创建publickey,但是它给出了以下错误。

C:\Users\fk>ssh-keygen
Generating public/private rsa key pair.
Enter file in which to save the key (//.ssh/id_rsa):
Could not create directory '//.ssh': No such file or directory
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
open //.ssh/id_rsa failed: No such file or directory.
Saving the key failed: //.ssh/id_rsa.

有人可以帮我解决这个问题吗?

谢谢。

1 个答案:

答案 0 :(得分:3)

之后:

输入要保存密钥的文件(//。ssh / id_rsa):

输入有效的Windows路径,D:\ id_rsa以创建私有公钥对,并将公钥添加到已知主机文件的其他主机