Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

ERROR CliDriver (SessionState.java:printError(426)) - Failed with exception java.io.IOException:java

Highlighted

ERROR CliDriver (SessionState.java:printError(426)) - Failed with exception java.io.IOException:java

New Contributor

i used version follow info:

 

jdk1.7.0_45

hadoop-2.3.0-cdh5.1.0/

hbase-0.98.1-cdh5.1.0/

hive-0.12.0-cdh5.1.0/

zookeeper-3.4.5-cdh5.1.0

===

hive CREATE EXTERNAL TABLE about hbase,and insert data for hbase;

 

CREATE EXTERNAL TABLE t1(key string ,cf string)
STORED BY 'org.apache.hadoop.hive.hbase.HBaseStorageHandler'
WITH SERDEPROPERTIES ("hbase.columns.mapping" = ":key,cf:cf1")
TBLPROPERTIES ("hbase.table.name" = "test");

 

CREATE TABLE tmp(id STRING ,name STRING) ROW FORMAT DELIMITED FIELDS TERMINATED BY '\t';
LOAD DATA LOCAL INPATH "/home/hadoop/hdfs/t.txt" INTO TABLE tmp;
insert overwrite table t1 select * from tmp;

 

anything do work ok; but in hive select do have any error:

 

hive> select * from t1;
14/08/18 10:37:17 INFO metastore.HiveMetaStore: 1: source:/10.10.4.207 get_table : db=default tbl=t1
14/08/18 10:37:17 INFO HiveMetaStore.audit: ugi=hadoop ip=/10.10.4.207 cmd=source:/10.10.4.207 get_table : db=default tbl=t1
14/08/18 10:37:17 DEBUG metastore.ObjectStore: Open transaction: count = 1, isActive = true at:
org.apache.hadoop.hive.metastore.ObjectStore.getTable(ObjectStore.java:795)
14/08/18 10:37:17 DEBUG metastore.ObjectStore: Open transaction: count = 2, isActive = true at:
org.apache.hadoop.hive.metastore.ObjectStore.getMTable(ObjectStore.java:856)
14/08/18 10:37:17 DEBUG metastore.ObjectStore: Commit transaction: count = 1, isactive true at:
org.apache.hadoop.hive.metastore.ObjectStore.getMTable(ObjectStore.java:864)
14/08/18 10:37:17 DEBUG metastore.ObjectStore: Commit transaction: count = 0, isactive true at:
org.apache.hadoop.hive.metastore.ObjectStore.getTable(ObjectStore.java:797)
OK
Failed with exception java.io.IOException:java.lang.NullPointerException
Time taken: 0.247 seconds

---

hive.log

 

2014-08-18 10:37:17,555 INFO parse.SemanticAnalyzer (SemanticAnalyzer.java:analyzeInternal(8317)) - Starting Semantic Analysis
2014-08-18 10:37:17,555 INFO parse.SemanticAnalyzer (SemanticAnalyzer.java:analyzeInternal(8352)) - Completed phase 1 of Semantic Analysis
2014-08-18 10:37:17,556 INFO parse.SemanticAnalyzer (SemanticAnalyzer.java:getMetaData(1064)) - Get metadata for source tables
2014-08-18 10:37:17,591 INFO parse.SemanticAnalyzer (SemanticAnalyzer.java:getMetaData(1171)) - Get metadata for subqueries
2014-08-18 10:37:17,591 INFO parse.SemanticAnalyzer (SemanticAnalyzer.java:getMetaData(1191)) - Get metadata for destination tables
2014-08-18 10:37:17,613 INFO parse.SemanticAnalyzer (SemanticAnalyzer.java:analyzeInternal(8355)) - Completed getting MetaData in Semantic Analysis
2014-08-18 10:37:17,687 INFO parse.SemanticAnalyzer (SemanticAnalyzer.java:analyzeInternal(8431)) - Completed plan generation
2014-08-18 10:37:17,687 INFO ql.Driver (Driver.java:compile(463)) - Semantic Analysis Completed
2014-08-18 10:37:17,690 INFO ql.Driver (Driver.java:getSchema(263)) - Returning Hive schema: Schema(fieldSchemas:[FieldSchema(name:key, type:string, comment:null), FieldSchema(name:cf, type:string, comment:null)], properties:null)
2014-08-18 10:37:17,690 INFO ql.Driver (Driver.java:createLockManager(167)) - Creating lock manager of type org.apache.hadoop.hive.ql.lockmgr.zookeeper.ZooKeeperHiveLockManager
2014-08-18 10:37:17,709 INFO ql.Driver (Driver.java:execute(1188)) - Starting command: select * from t1
2014-08-18 10:37:17,710 INFO ql.Driver (SessionState.java:printInfo(417)) - OK
2014-08-18 10:37:17,789 ERROR CliDriver (SessionState.java:printError(426)) - Failed with exception java.io.IOException:java.lang.NullPointerException
java.io.IOException: java.lang.NullPointerException
at org.apache.hadoop.hive.ql.exec.FetchOperator.getNextRow(FetchOperator.java:557)
at org.apache.hadoop.hive.ql.exec.FetchOperator.pushRow(FetchOperator.java:495)
at org.apache.hadoop.hive.ql.exec.FetchTask.fetch(FetchTask.java:139)
at org.apache.hadoop.hive.ql.Driver.getResults(Driver.java:1578)
at org.apache.hadoop.hive.cli.CliDriver.processLocalCmd(CliDriver.java:280)
at org.apache.hadoop.hive.cli.CliDriver.processCmd(CliDriver.java:220)
at org.apache.hadoop.hive.cli.CliDriver.processLine(CliDriver.java:422)
at org.apache.hadoop.hive.cli.CliDriver.executeDriver(CliDriver.java:790)
at org.apache.hadoop.hive.cli.CliDriver.run(CliDriver.java:684)
at org.apache.hadoop.hive.cli.CliDriver.main(CliDriver.java:623)
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)
Caused by: java.lang.NullPointerException
at org.apache.hadoop.net.DNS.reverseDns(DNS.java:92)
at org.apache.hadoop.hbase.mapreduce.TableInputFormatBase.reverseDNS(TableInputFormatBase.java:228)
at org.apache.hadoop.hbase.mapreduce.TableInputFormatBase.getSplits(TableInputFormatBase.java:191)
at org.apache.hadoop.hive.hbase.HiveHBaseTableInputFormat.getSplits(HiveHBaseTableInputFormat.java:480)
at org.apache.hadoop.hive.ql.exec.FetchOperator.getRecordReader(FetchOperator.java:386)
at org.apache.hadoop.hive.ql.exec.FetchOperator.getNextRow(FetchOperator.java:521)
... 14 more

 

anybody can help me,thanks