立即注册 登录
About云-梭伦科技 返回首页

zhanggl的个人空间 https://www.aboutyun.com/?5862 [收藏] [复制] [分享] [RSS]

日志

hive查询mysql元数据的时候出现需要手动导jar包到hdfs上

热度 1已有 979 次阅读2014-6-4 14:22 |个人分类:hbase和mysq整合

环境:
hive-0.10.0-cdh4.5.0 ,hadoop-2.0-4.5,
在查询hive 的数据时候出现找不到hdfs上的jar包需要手动导入:
select count(1) from weibo-qq
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
java.io.FileNotFoundException: File does not exist: hdfs://localhost:9000/home/hadoop/hive-0.10.0-cdh4.5.0/lib/hive-builtins-0.10.0-cdh4.5.0.jar
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
java.io.FileNotFoundException: File does not exist: hdfs://localhost:9000/home/hadoop/hive-0.10.0-cdh4.5.0/auxlib/zookeeper-3.4.5-cdh4.5.0.jar
    at org.apache.hadoop.hdfs.DistributedFileSystem.getFileStatus(DistributedFileSystem.java:824)
解决办法:把hive/lib下面对应的jar上传到HDFS上面对应的目录即可。
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
Job running in-process (local Hadoop)
2014-06-04 14:14:01,303 null map = 100%,  reduce = 100%
Ended Job = job_local357278961_0001
Execution completed successfully
Mapred Local Task Succeeded . Convert the Join into MapJoin
OK
7
我的hive-site.xml配置:
<property>
          <name>hive.metastore.local</name>
            <value>true</value>
          <description>
            controls whether to connect to remove metastore server or open a new metastore server in Hive Client JVM
        </description>
    </property>

 <property>
          <name>javax.jdo.option.ConnectionURL</name>
          <value>jdbc:mysql://localhost:3306/hive?createDatabaseIfNotExist=true</value>
          <description>JDBC connect string for a JDBC metastore</description>
        </property>

        <property>
          <name>javax.jdo.option.ConnectionDriverName</name>
          <value>com.mysql.jdbc.Driver</value>
          <description>Driver class name for a JDBC metastore</description>
        </property>

        <property>
          <name>javax.jdo.option.ConnectionUserName</name>
          <value></value>
          <description>username to use against metastore database</description>
        </property>

        <property>
          <name>javax.jdo.option.ConnectionPassword</name>
          <value></value>
          <description>password to use against metastore database</description>
        </property>

我有一点不明白为什么会出现这个问题。



路过

雷人

握手

鲜花

鸡蛋

发表评论 评论 (1 个评论)

回复 pig2 2014-6-4 19:10
这个跟配置有关系,程序会配置文件,找里面对应的jar包,如果找不到jar,肯定会报错。根据你展示的文件来看,你并没有配置,而是系统默认的路径。

facelist doodle 涂鸦板

您需要登录后才可以评论 登录 | 立即注册

关闭

推荐上一条 /2 下一条