2 pandy04 pandy04 于 2016.01.20 17:48 提问

hive错误: 不能实例化 HiveMetaStoreClient

使用hive 0.12和mysql 5.6, hive每次启动都报如下错误
16/01/20 15:42:19 WARN conf.HiveConf: DEPRECATED: Configuration property hive.metastore.local no longer has any effect. Make sure to provide a valid value for hive.metastore.uris if you are connecting to a remote metastore.

Logging initialized using configuration in jar:file:/home/zkpk/apache-hive-0.13.1-bin/lib/hive-common-0.13.1.jar!/hive-log4j.properties
SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/home/zkpk/hadoop-2.5.1/share/hadoop/common/lib/slf4j-log4j12-1.7.5.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/home/zkpk/hbase-0.98.7-hadoop2/lib/phoenix-4.5.1-HBase-0.98-client.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/home/zkpk/hbase-0.98.7-hadoop2/lib/slf4j-log4j12-1.6.4.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.slf4j.impl.Log4jLoggerFactory]
Exception in thread "main" java.lang.RuntimeException: java.lang.RuntimeException: Unable to instantiate org.apache.hadoop.hive.metastore.HiveMetaStoreClient
at org.apache.hadoop.hive.ql.session.SessionState.start(SessionState.java:346)
at org.apache.hadoop.hive.cli.CliDriver.run(CliDriver.java:681)
at org.apache.hadoop.hive.cli.CliDriver.main(CliDriver.java:625)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.apache.hadoop.util.RunJar.main(RunJar.java:212)

已经做过相应调查,但依然解决不了

  1. hive-site.xml的配置如下:

       
            hive.metastore.local
            true
       
       
            javax.jdo.option.ConnectionURL
             jdbc:mysql://master:3306/hive_13?characterEncoding=UTF-8
       
       
            javax.jdo.option.ConnectionDriverName
            com.mysql.jdbc.Driver
       
       
            javax.jdo.option.ConnectionUserName
            hadoop
       
       
            javax.jdo.option.ConnectionPassword
            hadoop
       

  2. hive用户可以成功连接mysql
    *****@master conf]$ mysql -uhadoop -p
    Enter password:
    Welcome to the MySQL monitor. Commands end with ; or \g.
    Your MySQL connection id is 35
    Server version: 5.1.73 Source distribution

Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> show databases;
+--------------------+
| Database |
+--------------------+
| information_schema |
| hive_13 |
| mydata |
| mysql |

  1. 在 $HIVE_HOME/lib下,有对应的mysql-connector [grid@hadoop1 conf]$ ls ../lib/mysql-connector-java-5.1.27-bin.jar -l -rw-r--r-- 1 grid grid 872303 Dec 8 23:31 ../lib/mysql-connector-java-5.1.27-bin.jar [grid@hadoop1 conf]$

1个回答

devmiao
devmiao   Ds   Rxr 2016.01.20 17:49
pandy04
pandy04 看过这个了 上面并没有解决的办法
2 年多之前 回复
Csdn user default icon
上传中...
上传图片
插入图片
准确详细的回答,更有利于被提问者采纳,从而获得C币。复制、灌水、广告等回答会被删除,是时候展现真正的技术了!
其他相关推荐
hive启动报错 hive.metastore.HiveMetaStoreClient
之前用的是hive-0.90 ,想与hbase整合下,所以更换hive为0.13.1版本,因为偷懒将原来的conf配置文件拷贝, 结果出现如下错误,hive.metastore.local,hive.metastore.ds.retry.*是新版本不建议使用,删除配置文件中的内容即可, java.lang.RuntimeException: Unable to instantiate or
hive错误 show tables 无法使用 : Unable to instantiate rg.apache.hadoop.hive.metastore.HiveMetaStoreClient
hive异常 show tables 无法使用 : Unable to instantiate rg.apache.hadoop.hive.metastore.HiveMetaStoreClient 异常: hive> show tables; FAILED: Error in metadata: java.lang.RuntimeException: Unable to instantia
Unable to instantiate org.apache.hadoop.hive.metastore.HiveMetaStoreClient
异常结果: hive> show databases; FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.DDLTask. java.lang.RuntimeException: Unable to instantiate org.apache.hadoop.hive.metastore.Hiv
Hive Metastore 代码简析
1.  hive metastore 内部结构 1.1 包结构 从package结构来看,主要的5个package,让我们来看看这几个package的内容 (1) metastorepackage是metastore 模块的入口,也是整个metastore模块的核心所在,里面包含了HiveMetaStore类作为整个模块的核心,接收来自hive的请求,返回需要的信息。 (2)
Unable to instantiate org.apache.hadoop.hive.metastore.HiveMetaStoreClient错误解决方法
1.ERROR: FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.DDLTask. java.lang.RuntimeException: Unable to instantiate org.apache.hadoop.hive.metastore.HiveMetaStoreClient
Hive metastore整体代码分析及详解
https://www.cnblogs.com/yangsy0915/p/8456806.html   从上一篇对Hive metastore表结构的简要分析中,我再根据数据设计的实体对象,再进行整个代码结构的总结。那么我们先打开metadata的目录,其目录结构:   可以看到,整个hivemeta的目录包含metastore(客户端与服务端调用逻辑)、events(事件目录包含
Hive Metastore Thrift Server Partition压力测试
测试环境: 虚拟机10.1.77.84 四核Intel(R) Xeon(R) CPU E5649  @ 2.53GHz,8G内存 起单台metastore server JVM args : -Xmx7000m -XX:ParallelGCThreads=8 -XX:+UseConcMarkSweepGC 测试表Schema: table name: metastore_s
Hive MetaStore 源码分析
1.启动脚本  $HIVE_HOME/bin/hive --service hivemetastore   --> $HIVE_HOME/bin/ ext/metastore.sh --> 可以看到入口类org.apache.hadoop.hive.metastore.HiveMetaStore 2.入口类 (1) cli.parse 解析参数 (2) LogUtils.i
hive异常 show tables 无法使用 : Unable to instantiate rg.apache.hadoop.hive.metastore.HiveMetaStoreClient
异常: hive> show tables; FAILED: Error in metadata: java.lang.RuntimeException: Unable to instantiate rg.apache.hadoop.hive.metastore.HiveMetaStoreClient  FAILED: Execution Error, return code 1 from
Hive客户端多并发问题解决方法记录
问题出现场景: 如用户描述:(  测试脚本如下: echo " set hive.exec.dynamic.partition=true; set hive.exec.dynamic.partition.mode=nonstrict; set hive.optimize.sort.dynamic.partition=false; set hive.exec.max.dyn