WARN conf.HiveConf:在大数据的CLASSPATH-TOS上找不到hive-site.xml

时间:2013-04-18 13:33:44

标签: hadoop hive hdfs talend

我是Hadoop新手。我正在为大数据发布Talend Open Studio。 我正在尝试与Hive相关的组件:tHiveConnection等。

执行作业时出现此错误:

[statistics] connecting to socket on port 3556
[statistics] connected
13/04/18 14:08:52 WARN conf.HiveConf: hive-site.xml not found on CLASSPATH
13/04/18 14:08:52 INFO metastore.HiveMetaStore: 0: Opening raw store with implemenation class:org.apache.hadoop.hive.metastore.ObjectStore
13/04/18 14:08:52 INFO metastore.ObjectStore: ObjectStore, initialize called
13/04/18 14:08:52 INFO DataNucleus.Persistence: Property datanucleus.cache.level2 unknown - will be ignored
13/04/18 14:08:54 INFO metastore.ObjectStore: Setting MetaStore object pin classes with hive.metastore.cache.pinobjtypes="Table,StorageDescriptor,SerDeInfo,Partition,Database,Type,FieldSchema,Order"
13/04/18 14:08:54 INFO metastore.ObjectStore: Initialized ObjectStore
Hive history file=/tmp/admin.qlv/hive_job_log_admin.qlv_201304181408_152240551.txt
13/04/18 14:08:55 INFO exec.HiveHistory: Hive history file=/tmp/admin.qlv/hive_job_log_admin.qlv_201304181408_152240551.txt
13/04/18 14:08:56 INFO service.HiveServer: Putting temp output to file \tmp\admin.qlv\admin.qlv_2013041814085651067019081102470.pipeout
13/04/18 14:08:56 INFO service.HiveServer: Running the query: set hive.fetch.output.serde = org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe
13/04/18 14:08:56 INFO service.HiveServer: Putting temp output to file \tmp\admin.qlv\admin.qlv_2013041814085651067019081102470.pipeout
13/04/18 14:08:56 INFO service.HiveServer: Running the query: SELECT    pokes.num,    pokes.val FROM pokes
13/04/18 14:08:56 INFO ql.Driver: <PERFLOG method=Driver.run>
13/04/18 14:08:56 INFO ql.Driver: <PERFLOG method=compile>
13/04/18 14:08:56 INFO parse.ParseDriver: Parsing command: SELECT    pokes.num,    pokes.val FROM pokes
13/04/18 14:08:56 INFO parse.ParseDriver: Parse Completed
13/04/18 14:08:56 INFO parse.SemanticAnalyzer: Starting Semantic Analysis
13/04/18 14:08:56 INFO parse.SemanticAnalyzer: Completed phase 1 of Semantic Analysis
13/04/18 14:08:56 INFO parse.SemanticAnalyzer: Get metadata for source tables
13/04/18 14:08:56 INFO hive.metastore: Trying to connect to metastore with URI thrift://:8020
13/04/18 14:08:56 ERROR parse.SemanticAnalyzer: org.apache.hadoop.hive.ql.metadata.HiveException: Unable to fetch table pokes
    at org.apache.hadoop.hive.ql.metadata.Hive.getTable(Hive.java:897)
    at org.apache.hadoop.hive.ql.metadata.Hive.getTable(Hive.java:831)
    at org.apache.hadoop.hive.ql.parse.SemanticAnalyzer.getMetaData(SemanticAnalyzer.java:954)
    at org.apache.hadoop.hive.ql.parse.SemanticAnalyzer.analyzeInternal(SemanticAnalyzer.java:7524)
    at org.apache.hadoop.hive.ql.parse.BaseSemanticAnalyzer.analyze(BaseSemanticAnalyzer.java:243)
    at org.apache.hadoop.hive.ql.Driver.compile(Driver.java:431)
    at org.apache.hadoop.hive.ql.Driver.compile(Driver.java:336)
    at org.apache.hadoop.hive.ql.Driver.run(Driver.java:909)
    at org.apache.hadoop.hive.service.HiveServer$HiveServerHandler.execute(HiveServer.java:191)
    at org.apache.hadoop.hive.jdbc.HiveStatement.executeQuery(HiveStatement.java:187)
    at org.apache.hadoop.hive.jdbc.HiveStatement.execute(HiveStatement.java:127)
    at bigdataproject.requetehive_0_1.RequeteHive.tHiveRow_1Process(RequeteHive.java:433)
    at bigdataproject.requetehive_0_1.RequeteHive.runJobInTOS(RequeteHive.java:660)
    at bigdataproject.requetehive_0_1.RequeteHive.main(RequeteHive.java:516)
Caused by: java.lang.NullPointerException
    at org.apache.thrift.transport.TSocket.open(TSocket.java:166)
    at org.apache.hadoop.hive.metastore.HiveMetaStoreClient.openStore(HiveMetaStoreClient.java:264)
    at org.apache.hadoop.hive.metastore.HiveMetaStoreClient.open(HiveMetaStoreClient.java:197)
    at org.apache.hadoop.hive.metastore.HiveMetaStoreClient.<init>(HiveMetaStoreClient.java:157)
    at org.apache.hadoop.hive.ql.metadata.Hive.createMetaStoreClient(Hive.java:2093)
    at org.apache.hadoop.hive.ql.metadata.Hive.getMSC(Hive.java:2103)
    at org.apache.hadoop.hive.ql.metadata.Hive.getTable(Hive.java:889)
    ... 13 more
FAILED: Error in semantic analysis: Unable to fetch table pokes
13/04/18 14:08:56 ERROR ql.Driver: FAILED: Error in semantic analysis: Unable to fetch table pokes
org.apache.hadoop.hive.ql.parse.SemanticException: Unable to fetch table pokes
    at org.apache.hadoop.hive.ql.parse.SemanticAnalyzer.getMetaData(SemanticAnalyzer.java:1129)
    at org.apache.hadoop.hive.ql.parse.SemanticAnalyzer.analyzeInternal(SemanticAnalyzer.java:7524)
    at org.apache.hadoop.hive.ql.parse.BaseSemanticAnalyzer.analyze(BaseSemanticAnalyzer.java:243)
    at org.apache.hadoop.hive.ql.Driver.compile(Driver.java:431)
    at org.apache.hadoop.hive.ql.Driver.compile(Driver.java:336)
    at org.apache.hadoop.hive.ql.Driver.run(Driver.java:909)
    at org.apache.hadoop.hive.service.HiveServer$HiveServerHandler.execute(HiveServer.java:191)
    at org.apache.hadoop.hive.jdbc.HiveStatement.executeQuery(HiveStatement.java:187)
    at org.apache.hadoop.hive.jdbc.HiveStatement.execute(HiveStatement.java:127)
    at bigdataproject.requetehive_0_1.RequeteHive.tHiveRow_1Process(RequeteHive.java:433)
    at bigdataproject.requetehive_0_1.RequeteHive.runJobInTOS(RequeteHive.java:660)
    at bigdataproject.requetehive_0_1.RequeteHive.main(RequeteHive.java:516)
Caused by: org.apache.hadoop.hive.ql.metadata.HiveException: Unable to fetch table pokes
    at org.apache.hadoop.hive.ql.metadata.Hive.getTable(Hive.java:897)
    at org.apache.hadoop.hive.ql.metadata.Hive.getTable(Hive.java:831)
    at org.apache.hadoop.hive.ql.parse.SemanticAnalyzer.getMetaData(SemanticAnalyzer.java:954)
    ... 11 more
Caused by: java.lang.NullPointerException
    at org.apache.thrift.transport.TSocket.open(TSocket.java:166)
    at org.apache.hadoop.hive.metastore.HiveMetaStoreClient.openStore(HiveMetaStoreClient.java:264)
    at org.apache.hadoop.hive.metastore.HiveMetaStoreClient.open(HiveMetaStoreClient.java:197)
    at org.apache.hadoop.hive.metastore.HiveMetaStoreClient.<init>(HiveMetaStoreClient.java:157)
    at org.apache.hadoop.hive.ql.metadata.Hive.createMetaStoreClient(Hive.java:2093)
    at org.apache.hadoop.hive.ql.metadata.Hive.getMSC(Hive.java:2103)
    at org.apache.hadoop.hive.ql.metadata.Hive.getTable(Hive.java:889)
    ... 13 more
13/04/18 14:08:56 INFO ql.Driver: </PERFLOG method=compile start=1366290536085 end=1366290536467 duration=382>
13/04/18 14:08:56 INFO ql.Driver: <PERFLOG method=releaseLocks>
13/04/18 14:08:56 INFO ql.Driver: </PERFLOG method=releaseLocks start=1366290536467 end=1366290536467 duration=0>
Query returned non-zero code: 10, cause: FAILED: Error in semantic analysis: Unable to fetch table pokes
[statistics] disconnected
你知道吗?

感谢。

1 个答案:

答案 0 :(得分:0)

最后,我找到了解决这个问题的方法。虽然很简单,但我花了很长时间才发现。

  1. 请确认端口 - &gt;对于独立模式,它应该是10000

  2. 输入“hive --service hiveserver”启动Hive Thrift Server

  3. 同时查看http://raj-hadoop.blogspot.in/2013/11/talend-open-studio-warn-confhiveconf.html

    多数民众赞成!你现在可以玩Talend了!