错误:
beeline>!connect jdbc:hive2://192.168.33.01:10000 root root
Connecting to jdbc:hive2://192.168.33.01:10000
Error: Failed to open new session: java.lang.RuntimeException: org.apache.hadoop.ipc.RemoteException(org.apache.hadoop.security.authorize.AuthorizationException): User: root is not allowed to impersonate root (state=,code=0)
解决办法:
在hadoop的core-site.xml中添加以下内容
- #(虚拟机的登录用户)“root”可以代理所有主机上的所有用户
- <property>
- <name>hadoop.proxyuser.root.hosts</name>
- <value>*</value>
- </property>
- <property>
- <name>hadoop.proxyuser.root.groups</name>
- <value>*</value>
- </property>