无法通过ssh登录服务器。所以用rsh登录并在尝试ssh主机本身时收到错误:
no common kex alg: client 'diffie-hellman-group-exchange-sha1,diffie-hellman-group1-sha1', server 'gss-group1-sha1-toWM5Slw5Ew8Mqkay+al2g=='
我在/var/svc/log/network-ssh:default.log
[ May 14 21:23:13 Rereading configuration. ]
[ May 14 21:23:13 Executing refresh method ("/lib/svc/method/sshd restart") ]
[ May 14 21:23:13 Method "refresh" exited with status 0 ]
[ May 14 21:30:25 Stopping because service disabled. ]
[ May 14 21:30:25 Executing stop method (:kill) ]
[ May 14 21:33:08 Enabled. ]
[ May 14 21:33:08 Executing start method ("/lib/svc/method/sshd start") ]
Could not load host key: /.ssh/id_dsa
Could not load host key: /.ssh/identity
Disabling protocol version 1. Could not load host key
[ May 14 21:33:08 Method "start" exited with status 0 ]
提前感谢。
答案 0 :(得分:4)
看起来服务器和客户端找不到通用的身份验证方法。
我刚刚在这里使用sun集群:它只支持diffie-hellman-group-exchange-sha1,diffie-hellman-group1-sha1
,但我的Gentoo GNU / Linux ssh服务器似乎已经放弃了group1算法。
通过更改ssh服务器上的/etc/ssh/sshd_config
以包含
KexAlgorithms curve25519-sha256@libssh.org,diffie-hellman-group1-sha1,diffie-hellman-group14-sha1,diffie-hellman-group-exchange-sha1,diffie-hellman-group-exchange-sha256,ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521
但是,我担心有理由从默认值中删除group1算法。我不会在公开的盒子上这样做。
答案 1 :(得分:2)
打开详细的ssh,希望能够显示问题所在。
E.g。
ssh -v host
如果没有提供足够的信息,您可以尝试
ssh -vv host
甚至
ssh -vvv host
查看输出中的第一个错误,希望能为您提供问题所在的线索。