环境
HBase 1.5
Hadoop 2.9.2
Zookeeper 3.5.6
[将Zookeeper配置为使用Kerberos并配置HBase jaas.conf
登录配置后,收到以下错误
...在hbase-master.log
中
ERROR org.apache.zookeeper.ClientCnxn: SASL authentication with Zookeeper Quorum member failed:
javax.security.sasl.SaslException: An error: (java.security.PrivilegedActionException:
javax.security.sasl.SaslException: GSS initiate failed
[Caused by GSSException: No valid credentials provided
(Mechanism level: Failed to find any Kerberos tgt)])
occurred when evaluating Zookeeper Quorum Member's received SASL token.
Zookeeper Client will go to AUTH_FAILED state.
HBase jaas.conf
Client {
com.sun.security.auth.module.Krb5LoginModule required
useKeyTab=true
useTicketCache=true
storeKey=true
keyTab="/etc/security/keytabs/hbase.keytab"
principal="hbase/@REALM.COM";
};
hbase-env.sh
export HBASE_OPTS="-Djava.security.auth.login.config=/opt/hbase/conf/jaas.conf"
jaas.conf
的正确方法: