2016-10-04 35 views
0

只有简单的SELECT查询实际上是在返回数据。所有其他查询概略地表示下列消息后停止处理:SUM或COUNT无效的HiveQL查询

Logging initialized using configuration in jar:file:/usr/local/hive/lib/hive-common-2.1.0.jar!/hive-log4j2.properties Async: true 
WARNING: Hive-on-MR is deprecated in Hive 2 and may not be available in the future versions. Consider using a different execution engine (i.e. tez, spark) or using Hive 1.X releases. 
Query ID = root_20161004163653_24333e2f-b221-4639-9b6c-69161aa5a41d 
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> 
+0

Hadoop版本?发行版?在云中,在多节点裸机群集上,在沙箱中?运行传统的'hive'事实CLI,或'beeline'或sthg其他?什么样的桌子 - EXTERNAL/managed,Text/AVRO/Parquet/ORC? –

+0

Metastore托管在MySQL,PostgreSQL,德比?你检查过ZK锁('show locks')吗? –

回答

0

简单的SELECT查询工作正常,原因是他们将不会触发地图减少后台工作。

Hive-on-MR在Hive 2版本中已被弃用,因为其他更现代且积极开发的执行引擎已经可以在一段时间内投入生产。未来的2.X版本可能会删除该支持。考虑使用不同的执行引擎(即spark,tez),或者如果要继续使用MR,请使用Hive 1.X版本。

检查link,您可能不得不使用spark或Tez作为您的执行引擎或使用旧版本的Hive。