Hbase - Kerberos 인증 예외
gt; 예전에는 아무리 노력해도 인증을 받을 수 없었습니다. 문제를 발견한 후에는 그 이상 현상이 실제 작동과 일치하지 않는다는 사실을 발견하여 모두에게 기록해 두었습니다. .
```
KrbException: Kerberos 데이터베이스에서 서버를 찾을 수 없습니다(7) - LOOKING_UP_SERVER
gt; cn
at sun.security.krb5.KrbTgsRep.lt; initgt; (KrbTgsRep.java: 73)
gt; req 유형은 13입니다
at sun.security.krb5.KrbTgsReq.getReply(KrbTgsReq.java: 251)
gt;gt;gt;KRBError:
at sun.security.krb5.KrbTgsReq.sendAndGetCreds(KrbTgsReq.java:262)
c시간은 8월 18일 금요일 02:49:26 CST 2000 966538166000
s시간은 7월 31일 화요일 11입니다. :59:12 CST 2018 1533009552000
at sun.security.krb5.internal.CredentialsUtil.serviceCreds(CredentialsUtil.java:308)
suSec는 97126
오류 코드는 sun.security.krb5.internal.CredentialsUtil.acquireServiceCreds(CredentialsUtil.java:126)에서 7
입니다.
오류 메시지는 Kerberos 데이터베이스에서 서버를 찾을 수 없습니다.
sun.security.krb5.Credentials.acquireServiceCreds(Credentials.java:458)
cname은 sun에서 hbase/lake.dounine.com@dounine.com
입니다. security.jgss.krb5.Krb5Context.initSecContext(Krb5Context.java: 693)
sname은 hbase/120.77.207.19@dounine.com입니다.
msgType은 30입니다.
sun.security.jgss.GSSContextImpl.initSecContext(GSSContextImpl.java:248)
at sun.security.jgss.GSSContextImpl.initSecContext(GSSContextImpl.java:179)
at com.sun.security.sasl.gsskerb.GssKrb5Client.evaluateChallenge(Gss
Krb5Client.java:192)
(org.apache.hadoop.hbase.security.AbstractHBaseSaslRpcClient.getInitialResponse(AbstractHBaseSaslRpcClient.java:131))
(org.apache.hadoop.hbase). security.NettyHBaseSaslRpcClientHandler$1.run(NettyHBaseSaslRpcClientHandler.java:108)
at org.apache.hadoop.hbase.security.NettyHBaseSaslRpcClientHandler$1.run(NettyHBaseSaslRpcClientHandler.java:104)
at java.security.AccessController.doPrivileged(네이티브 메소드)
- javax.security.auth.Subject.doAs(Subject.java:422)
- org.apache.hadoop.security .UserGroupInformation.doAs(UserGroupInformation.java:1746)
org.apache.hadoop.hbase.security.NettyHBaseSaslRpcClientHandler.handlerAdded(NettyHBaseSaslRpcClientHandler.java:104)
org.apache .hbase.thirdparty.io.netty.channel.DefaultChannelPipeline.callHandlerAdded0(DefaultChannelPipeline.java:606)
at org.apache.hbase.thirdparty.io.netty.channel.DefaultChannelPipeline.addFirst(DefaultChannelPipeline.java :187)
org.apache.hbase.thirdparty.io.netty.channel.DefaultChannelPipeline.addFirst(DefaultChannelPipeline.java:380)
org.apache.hbase.thirdparty .io.netty.channel.DefaultChannelPipeline.addFirst(DefaultChannelPipeline.java:359)
at org.apache.hadoop.hbase.ipc.NettyRpcConnection.saslNegotiate(NettyRpcConnection.java:200)
org.apache.hadoop.hbase.ipc.NettyRpcConnection.access$800(N
ettyRpcConnection.java: 71)
org.apache.hadoop.hbase.ipc.NettyRpcConnection$3.erationComplete(NettyRpcConnection.java: 273)
org.apache.hadoop.hbase .ipc.NettyRpcConnection$3.OperationComplete(NettyRpcConnection.java:261)
at org.apache.hbase.thirdparty.io.netty.util.concurrent.DefaultPromise.notifyListener0(DefaultPromise.java:507) p>
(org.apache.hbase.thirdparty.io.netty.util.concurrent.DefaultPromise.notifyListeners0(DefaultPromise.java:500))
(org.apache.hbase.thirdparty.io). netty.util.concurrent.DefaultPromise.notifyListenersNow(DefaultPromise.java:479)
at org.apache.hbase.thirdparty.io.netty.util.concurrent.DefaultPromise.notifyListeners(DefaultPromise.java:420)
org.apache.hbase.thirdparty.io.netty.util.concurrent.DefaultPromise.trySuccess(DefaultPromise.java:104)
org.apache.hbase.thirdparty. io.netty.channel.DefaultChannelPromise.trySuccess(DefaultChannelPromise.java:82)
at org.apache.hbase.thirdparty.io.netty.channel.nio.AbstractNioChannel$AbstractNioUnsafe.fulfillConnectPromise(AbstractNioChannel.java: 306)
org.apache.hbase.thirdparty.io.netty.channel.nio.AbstractNioChannel$AbstractNioUnsafe.finishConnect(AbstractNioChannel.java:341)
org.apache에서. hbase.thirdparty.io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:633)
org.apache.hbase.thirdparty.io.netty.c
Channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:580)
at org.apache.hbase.thirdparty.io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:497) p> p>
(org.apache.hbase.thirdparty.io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:459))
(org.apache.hbase.thirdparty). io.netty.util.concurrent.SingleThreadEventExecutor$5.run(SingleThreadEventExecutor.java:858)
at org.apache.hbase.thirdparty.io.netty.util.concurrent.DefaultThreadFactory$DefaultRunnableDecorator.run(DefaultThreadFactory .java :138)
at java.lang.Thread.run(Thread.java:748)
원인: KrbException: 식별자가 예상 값과 일치하지 않습니다(906)< /p >
sun.security.krb5.internal.KDCRep.init(KDCRep.java:140)
sun.security.krb5.internal.TGSRep.init(TGSRep.java:65) )
sun.security.krb5.internal.TGSRep.lt;initgt;(TGSRep.java:60)
sun.security.krb5.KrbTgsRep.lt;initgt; (KrbTgsRep .java: 55)
... 39 more
```
이 오류에는 온라인 서버의 도메인 이름 매핑이 필요합니다. /etc/hosts`
```
10.10.0.2 h1.demo.com
10.10.0.3 h2.demo.com
10.10.0.4 h3.demo.com
```
---
![](https://upload -images.jianshu .io/upload_images/9028759-07315bb8dadcd082.png?imageMogr2/auto-orient/strip7CimageView2/2/w/1240)