hive启动hiveserver2连JDBC报错:Could not open client transport with JDBC Uri解决方案

开启hiveserver2和beeline后jdbc报错Could not open client transport with JDBC Uri

0: jdbc:hive2://hadoop100:10000(closed)> 

报错信息

Error: Could not open client transport with JDBC Uri: jdbc:hive2://hadoop100:10000/hive_metadata;user=hadoop: java.net.ConnectException: 拒绝连接 (Connection refused) (state=08S01,code=0)
Beeline version 2.3.3 by Apache Hive

解决方案:

在hadoop文件core-site.xml中配置信息如下,重启HDFS和Yarn,再次启动hiveserver2和beeline即可


    hadoop.proxyuser.hadoop.hosts
    *


    hadoop.proxyuser.hadoop.groups
    *

ok,hive的jdbc连接正常了

beeline> !connect jdbc:hive2://hadoop100:10000
Connecting to jdbc:hive2://hadoop100:10000
Enter username for jdbc:hive2://hadoop100:10000: kevin
Enter password for jdbc:hive2://hadoop100:10000: 
Connected to: Apache Hive (version 1.2.1)
Driver: Hive JDBC (version 1.2.1)
Transaction isolation: TRANSACTION_REPEATABLE_READ
0: jdbc:hive2://hadoop100:10000>

 

你可能感兴趣的:(Hive)