ssh证书登陆问题,验证正常登陆失败
ssh -vvvv 192.168.2.21 -p 2222 -o GSSAPIAuthentication=no 测试结果
192.168.2.29远程主机提示失败
debug2: input_userauth_pk_ok: SHA1 fp 22:89:e7:fa:21:76:7c:2c:8d:d1:c0:4a:50:b0:c4:77:f2:56:6c:b4
debug3: sign_and_send_pubkey: RSA 22:89:e7:fa:21:76:7c:2c:8d:d1:c0:4a:50:b0:c4:77:f2:56:6c:b4
debug3: no such identity: /root/.ssh/id_rsa
debug1: Trying private key: /root/.ssh/id_dsa
debug3: no such identity: /root/.ssh/id_dsa
debug1: Trying private key: /root/.ssh/id_ecdsa
debug3: no such identity: /root/.ssh/id_ecdsa
debug2: we did not send a packet, disable method
文件权限
[root@mail ~]# ll .ssh -R
.ssh:
total 12
-rw-r--r--. 1 root root 408 Aug 9 09:20 authorized_keys
-rw-r--r--. 1 root root 408 Aug 9 09:15 id_rsa.pub
-rw-r--r--. 1 root root 1587 Aug 8 18:02 known_hosts
192.168.2.21源主机提示正常
debug2: input_userauth_pk_ok: SHA1 fp 22:89:e7:fa:21:76:7c:2c:8d:d1:c0:4a:50:b0:c4:77:f2:56:6c:b4
debug3: sign_and_send_pubkey: RSA 22:89:e7:fa:21:76:7c:2c:8d:d1:c0:4a:50:b0:c4:77:f2:56:6c:b4
debug1: read PEM private key done: type RSA
debug3: Wrote 640 bytes for a total of 2285
debug1: Authentication succeeded (publickey).
文件权限
[root@localhost ~]# ll .ssh -R
.ssh:
total 16
-rw-r--r-- 1 root root 408 Jul 16 17:19 authorized_keys
-rw------- 1 root root 1675 Jul 16 17:13 id_rsa
-rw-r--r-- 1 root root 408 Jul 16 17:13 id_rsa.pub
-rw-r--r-- 1 root root 401 Jul 16 17:22 known_hosts
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
debug报错:
debug3: no such identity: /root/.ssh/id_dsa
执行:
ssh-keygen -f ~/.ssh/identity
参考:https://bbs.archlinux.org/vie...
如果上面的没用,看看这个:http://unix.stackexchange.com...