publickey,gssapi-with-mic,Unspecified GSS failure_VMware, Unix及操作系统讨论区_Weblogic技术|Tuxedo技术|中间件技术|Oracle论坛|JAVA论坛|Linux/Unix技术|hadoop论坛_联动北方技术论坛  
网站首页 | 关于我们 | 服务中心 | 经验交流 | 公司荣誉 | 成功案例 | 合作伙伴 | 联系我们 |
联动北方-国内领先的云技术服务提供商
»  游客             当前位置:  论坛首页 »  自由讨论区 »  VMware, Unix及操作系统讨论区 »
总帖数
1
每页帖数
101/1页1
返回列表
0
发起投票  发起投票 发新帖子
查看: 1945 | 回复: 0   主题: publickey,gssapi-with-mic,Unspecified GSS failure        下一篇 
无止境
注册用户
等级:新兵
经验:64
发帖:74
精华:0
注册:2011-11-14
状态:离线
发送短消息息给无止境 加好友    发送短消息息给无止境 发消息
发表于: IP:您无权察看 2015-7-13 11:18:54 | [全部帖] [楼主帖] 楼主

1、故障现象

# masterha_check_ssh --conf=/etc/app1.cnf
Wed Apr  8 14:33:26 2015 - [warning] Global configuration file /etc/masterha_default.cnf not found. Skipping.
...............
Permission denied (publickey,gssapi-with-mic,password).
Wed Apr  8 14:33:26 2015 - [error][/usr/lib/perl5/site_perl/5.8.8/MHA/SSHCheck.pm, ln86] SSH connection from
root@vdbsrv1(192.168.1.6:22) to root@vdbsrv2(192.168.1.7:22) failed!
### ssh到另一主机时,花费20s左右
# time ssh 192.168.1.7 date
Wed Apr 15 21:33:53 CST 2015
real   0m20.245s
user   0m0.013s
sys 0m0.007s
### 使用-v参数ssh连接
# ssh -v 192.168.1.7
OpenSSH_4.3p2, OpenSSL 0.9.8e-fips-rhel5 01 Jul 2008
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: Applying options for *
debug1: Connecting to 192.168.1.7 [192.168.1.7] port 22.
debug1: Connection established.
debug1: permanently_set_uid: 0/0
debug1: identity file /root/.ssh/identity type -1
debug1: identity file /root/.ssh/id_rsa type 1
debug1: identity file /root/.ssh/id_dsa type -1
debug1: loaded 3 keys
debug1: Remote protocol version 2.0, remote software version OpenSSH_4.3
debug1: match: OpenSSH_4.3 pat OpenSSH*
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_4.3
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: server->client aes128-ctr hmac-md5 none
debug1: kex: client->server aes128-ctr hmac-md5 none
debug1: SSH2_MSG_KEX_DH_GEX_REQUEST(1024<1024<8192) sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP
debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
debug1: Host '192.168.1.7' is known and matches the RSA host key.
debug1: Found key in /root/.ssh/known_hosts:1
debug1: ssh_rsa_verify: signature correct
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: SSH2_MSG_NEWKEYS received
debug1: SSH2_MSG_SERVICE_REQUEST sent
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue: publickey,gssapi-with-mic,password
debug1: Next authentication method: gssapi-with-mic
debug1: Unspecified GSS failure.  Minor code may provide more information
No credentials cache found
debug1: Unspecified GSS failure.  Minor code may provide more information
No credentials cache found
debug1: Unspecified GSS failure.  Minor code may provide more information
No credentials cache found
debug1: Next authentication method: publickey
debug1: Trying private key: /root/.ssh/identity
debug1: Offering public key: /root/.ssh/id_rsa
debug1: Server accepts key: pkalg ssh-rsa blen 277
debug1: read PEM private key done: type RSA
debug1: Authentication succeeded (publickey).
debug1: channel 0: new [client-session]
debug1: Entering interactive session.
debug1: Sending environment.
debug1: Sending env LANG = en_US.UTF-8
Last login: Wed Apr 15 16:56:12 2015 from 192.168.1.124


2、故障解决

###查看目标端的GSSAPI options
[root@vdbsrv2 ~]# grep GSSAPI /etc/ssh/sshd_config
# GSSAPI options
#GSSAPIAuthentication no
GSSAPIAuthentication yes      ###此时为开启GSSAPI认证
#GSSAPICleanupCredentials yes
GSSAPICleanupCredentials yes
[root@vdbsrv2 ~]# cp /etc/ssh/sshd_config /etc/ssh/sshd_config.bk
[root@vdbsrv2 ~]# vi /etc/ssh/sshd_config           ###关闭该认证方式
[root@vdbsrv2 ~]# grep GSSAPI /etc/ssh/sshd_config  ###查看关闭后的结果
# GSSAPI options
GSSAPIAuthentication no
#GSSAPIAuthentication yes
#GSSAPICleanupCredentials yes
GSSAPICleanupCredentials yes
###重启sshd服务
[root@vdbsrv2 ~]# service sshd restart
Stopping sshd: [  OK  ]
Starting sshd: [  OK  ]
###再次测试,仅仅0.191s,ssh -v时也无异常报错
[root@vdbsrv1 ~]# time ssh 192.168.1.7 date
Wed Apr 15 21:48:10 CST 2015
real   0m0.191s
user   0m0.014s
sys 0m0.003s


--转自 北京联动北方科技有限公司




赞(0)    操作        顶端 
总帖数
1
每页帖数
101/1页1
返回列表
发新帖子
请输入验证码: 点击刷新验证码
您需要登录后才可以回帖 登录 | 注册
技术讨论