Could not load host key: /etc/ssh/ssh_host_rsa_key /etc/ssh/ssh_host_dsa_key问题
2011-12-12 22:55
507 查看
Could not load host key: /etc/ssh/ssh_host_rsa_key
Could not load host key: /etc/ssh/ssh_host_dsa_key
问题的解决
症状:
用命令/usr/sbin/sshd启动sshd时出现:
系统提示“Could not load host key: /etc/ssh/ssh_host_key
Could not load host key: /etc/ssh/ssh_host_rsa_key
Could not load host key: /etc/ssh/ssh_host_dsa_key
Disabling protocol version 1. Could not load host key
Disabling protocol version 2. Could not load host key
sshd: no hostkeys available — exiting”
大致的意思就是需要某个key什么的。
问题所在:
1、系统丢失了ssh_host_dsa_key和ssh_host_rsa_key
2、用户没有权限访问这两个key
解决办法如下:
1、系统丢失了两个key时:
在终端中输入:ssh-keygen -t dsa -f /etc/ssh/ssh_host_dsa_key重新建立ssh_host_dsa_key文件
以下是返回信息
Generating public/private dsa key pair.
Enter passphrase (empty for no passphrase):(直接回车)
Enter same passphrase again:
Your identification has been saved in /etc/ssh/ssh_host_dsa_key.
Your public key has been saved in /etc/ssh/ssh_host_dsa_key.pub.
The key fingerprint is:
xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx root@localhost.localdomain
在终端中输入:ssh-keygen -t rsa -f /etc/ssh/ssh_host_rsa_key重新建立ssh_host_rsa_key文件
以下是返回信息
Generating public/private rkey pair.
Enter passphrase (empty for no passphrase):(直接回车)
Enter same passphrase again:
Your identification has been saved in /etc/ssh/ssh_host_rsa_key.
Your public key has been saved in /etc/ssh/ssh_host_dsa_rey.pub.
root@localhost.localdomain
现在用
/usr/sbin/sshd
即可成功启动sshd
这时候,就可以在windows底下使用putty连接这台linux主机了。
2、当前用户没有权限的时候用命令
/usr/sbin/sshd
启动sshd的时候也会这样,所以这是检查是否是root用户,一般root用户才能执行这个操作
Could not load host key: /etc/ssh/ssh_host_dsa_key
问题的解决
症状:
用命令/usr/sbin/sshd启动sshd时出现:
系统提示“Could not load host key: /etc/ssh/ssh_host_key
Could not load host key: /etc/ssh/ssh_host_rsa_key
Could not load host key: /etc/ssh/ssh_host_dsa_key
Disabling protocol version 1. Could not load host key
Disabling protocol version 2. Could not load host key
sshd: no hostkeys available — exiting”
大致的意思就是需要某个key什么的。
问题所在:
1、系统丢失了ssh_host_dsa_key和ssh_host_rsa_key
2、用户没有权限访问这两个key
解决办法如下:
1、系统丢失了两个key时:
在终端中输入:ssh-keygen -t dsa -f /etc/ssh/ssh_host_dsa_key重新建立ssh_host_dsa_key文件
以下是返回信息
Generating public/private dsa key pair.
Enter passphrase (empty for no passphrase):(直接回车)
Enter same passphrase again:
Your identification has been saved in /etc/ssh/ssh_host_dsa_key.
Your public key has been saved in /etc/ssh/ssh_host_dsa_key.pub.
The key fingerprint is:
xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx root@localhost.localdomain
在终端中输入:ssh-keygen -t rsa -f /etc/ssh/ssh_host_rsa_key重新建立ssh_host_rsa_key文件
以下是返回信息
Generating public/private rkey pair.
Enter passphrase (empty for no passphrase):(直接回车)
Enter same passphrase again:
Your identification has been saved in /etc/ssh/ssh_host_rsa_key.
Your public key has been saved in /etc/ssh/ssh_host_dsa_rey.pub.
root@localhost.localdomain
现在用
/usr/sbin/sshd
即可成功启动sshd
这时候,就可以在windows底下使用putty连接这台linux主机了。
2、当前用户没有权限的时候用命令
/usr/sbin/sshd
启动sshd的时候也会这样,所以这是检查是否是root用户,一般root用户才能执行这个操作
相关文章推荐
- sshd 无法启用的问题 Could not load host key: /etc/ssh/ssh_host_rsa_key Could not load host key: /etc/ssh/ss
- 启动ssh服务时,提示Could not load host key: /etc/ssh/ssh_host_rsa_key
- Could not load host key: /etc/ssh/ssh_host_rsa_key
- SSH 提示Could not load host key: /etc/ssh/ssh_host_rsa_key
- 启动ssh服务时,提示Could not load host key: /etc/ssh/ssh_host_rsa_key
- ssh报错:Could not load host key:/etc/ssh/ssh_host_rsa_key&ssh_host_ecdsa_key&ssh_host_ed25519_key
- could not load host key: /etc/ssh/ssh_host_rsa_key 无法启动ssh的一个解决办法
- could not load host key: /etc/ssh/ssh_host_rsa_key SSH无法连接
- 启动ssh服务时,提示Could not load host key: /etc/ssh/ssh_host_rsa_key
- NetBSD could not load host key: /etc/ssh/ssh_host_rsa_key 无法启动ssh的一个解决办法
- could not load host key: /etc/ssh/ssh_host_rsa_key 无法启动ssh的一个解决办法
- 全志open-ssh Could not load host key: /etc/ssh/ssh_host_key问题
- ssh异常-Could not load host key: /etc/ssh/ssh_host_ed25519_key
- Linux系统 CentOS 7 Permission 0755 for /etc/ssh/ssh_host_rsa_key"问题解决办法
- 启动sshd时,报“Could not load host key”错
- Linux有问必答:如何修复“sshd error: could not load host key”
- “sshd error: could not load host key”解决
- ssh: Could not resolve hostname问题终于解决了。
- 启动sshd时,报“Could not load host key”错
- 启动sshd时,报“Could not load host key”错