分享

在hadoop2.6.4上安装hive1.2.1,但一执行mapreduce报错

zzg_999 发表于 2016-10-9 17:35:21 [显示全部楼层] 回帖奖励 阅读模式 关闭右栏 3 7682
各位大侠好:
       我在hadoop2.6.4上安装hive1.2.1,但一执行mapreduce报错,如语句:select count(*) from b_barcode_prize_consumer , 报错如下(请哪位大侠给指点一二,这个问题困扰了我好几天了,多谢):
hive (default)> select count(*) from b_barcode_prize_consumer ;
Query ID = root_20161009101818_4b214fec-ed2f-4b28-8fd6-4ac9a0373b54
Total jobs = 1
Launching Job 1 out of 1
Number of reduce tasks determined at compile time: 1
In order to change the average load for a reducer (in bytes):
  set hive.exec.reducers.bytes.per.reducer=<number>
In order to limit the maximum number of reducers:
  set hive.exec.reducers.max=<number>
In order to set a constant number of reducers:
  set mapreduce.job.reduces=<number>
java.lang.NoSuchMethodError: org.apache.hadoop.mapred.JobStatus.<init>(Lorg/apache/hadoop/mapred/JobID;FFFFILorg/apache/hadoop/mapred/JobPriority;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;ZLjava/lang/String;)V
    at org.apache.hadoop.mapreduce.TypeConverter.fromYarn(TypeConverter.java:301)
    at org.apache.hadoop.mapred.ClientServiceDelegate.getJobStatus(ClientServiceDelegate.java:434)
    at org.apache.hadoop.mapred.YARNRunner.submitJob(YARNRunner.java:304)
    at org.apache.hadoop.mapreduce.JobSubmitter.submitJobInternal(JobSubmitter.java:241)
    at org.apache.hadoop.mapreduce.Job$10.run(Job.java:1297)
    at org.apache.hadoop.mapreduce.Job$10.run(Job.java:1294)
    at java.security.AccessController.doPrivileged(Native Method)
    at javax.security.auth.Subject.doAs(Subject.java:415)
    at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1656)
    at org.apache.hadoop.mapreduce.Job.submit(Job.java:1294)
    at org.apache.hadoop.mapred.JobClient$1.run(JobClient.java:562)
    at org.apache.hadoop.mapred.JobClient$1.run(JobClient.java:557)
    at java.security.AccessController.doPrivileged(Native Method)
    at javax.security.auth.Subject.doAs(Subject.java:415)
    at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1656)
    at org.apache.hadoop.mapred.JobClient.submitJobInternal(JobClient.java:557)
    at org.apache.hadoop.mapred.JobClient.submitJob(JobClient.java:548)
    at org.apache.hadoop.hive.ql.exec.mr.ExecDriver.execute(ExecDriver.java:428)
    at org.apache.hadoop.hive.ql.exec.mr.MapRedTask.execute(MapRedTask.java:137)
    at org.apache.hadoop.hive.ql.exec.Task.executeTask(Task.java:160)
    at org.apache.hadoop.hive.ql.exec.TaskRunner.runSequential(TaskRunner.java:88)
    at org.apache.hadoop.hive.ql.Driver.launchTask(Driver.java:1638)
    at org.apache.hadoop.hive.ql.Driver.execute(Driver.java:1397)
    at org.apache.hadoop.hive.ql.Driver.runInternal(Driver.java:1183)
    at org.apache.hadoop.hive.ql.Driver.run(Driver.java:1049)
    at org.apache.hadoop.hive.ql.Driver.run(Driver.java:1039)
    at org.apache.hadoop.hive.cli.CliDriver.processLocalCmd(CliDriver.java:207)
    at org.apache.hadoop.hive.cli.CliDriver.processCmd(CliDriver.java:159)
    at org.apache.hadoop.hive.cli.CliDriver.processLine(CliDriver.java:370)
    at org.apache.hadoop.hive.cli.CliDriver.executeDriver(CliDriver.java:754)
    at org.apache.hadoop.hive.cli.CliDriver.run(CliDriver.java:675)
    at org.apache.hadoop.hive.cli.CliDriver.main(CliDriver.java:615)
    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.run(RunJar.java:221)
    at org.apache.hadoop.util.RunJar.main(RunJar.java:136)
FAILED: Execution Error, return code -101 from org.apache.hadoop.hive.ql.exec.mr.MapRedTask. org.apache.hadoop.mapred.JobStatus.<init>(Lorg/apache/hadoop/mapred/JobID;FFFFILorg/apache/hadoop/mapred/JobPriority;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;ZLjava/lang/String;)V


已有(4)人评论

跳转到指定楼层
qcbb001 发表于 2016-10-9 19:07:20
应该是版本不一致造成的,是否有hbase,可以将
将正在运行的HBase和Zookeeper的jar包放到Hive  的lib目录下,删除hive下原来版本的jar包。

做好备份
回复

使用道具 举报

zzg_999 发表于 2016-10-9 19:57:42
你好:
      我之前已把HBase的lib/hbase-*.jar和htrace-core-2.04.jar及zookeeper-3.4.6.jar拷贝到hive的lib目录下了,不知是什么问题

点评

这个应该就是版本不一致造成的,说明复制的不够全,细心很重要,而不是一个命令复制  发表于 2016-10-10 07:55
回复

使用道具 举报

zzg_999 发表于 2016-10-10 22:57:45
是hive/lib下的jar 和 hadoop/share/hadoop/yarn/lib下的jar比较吗,是把ive/lib下的jar复制到hadoop/share/hadoop/yarn/lib下吗,还是相反,谢谢大侠能进一步指点1、2
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

关闭

推荐上一条 /2 下一条