Cloudera CDH/CDP 및 Hadoop EcoSystem, Semantic IoT등의 개발/운영 기술을 정리합니다. gooper@gooper.com로 문의 주세요.
hive beeline으로 접근시 "User: gooper is not allowed to impersonate anonymous (state=08S01,code=0)"가 발생하면서 "No current connection"이 발생하는 경우 조치
bin/beeline -n $(whoami) -u jdbc:hive2://localhost:10000와 같이 -n을 지정해서 beeline을 실행해준다.
-----------------------오류 내용------------------------------
gooper@gsda1:~/hive/bin$ beeline -u jdbc:hive2://gsda1:10000
SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/svc/apps/gsda/bin/hadoop/apache-hive-2.1.1-bin/lib/log4j-slf4j-impl-2.4.1.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/svc/apps/gsda/bin/hadoop/hadoop-2.8.0/share/hadoop/common/lib/slf4j-log4j12-1.7.10.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
SLF4J: Actual binding is of type [org.apache.logging.slf4j.Log4jLoggerFactory]
Connecting to jdbc:hive2://gsda1:10000
18/04/15 15:58:34 [main]: WARN jdbc.HiveConnection: Failed to connect to gsda1:10000
Error: Could not open client transport with JDBC Uri: jdbc:hive2://gsda1:10000: Failed to open new session: java.lang.RuntimeException: org.apache.hadoop.ipc.RemoteException(org.apache.hadoop.security.authorize.AuthorizationException): User: gooper is not allowed to impersonate anonymous (state=08S01,code=0)
Beeline version 2.1.1 by Apache Hive
beeline>
beeline>
beeline>
beeline> show databases;
No current connection