首页 > 代码库 > Hive报错:Failed with exception Unable to rename

Hive报错:Failed with exception Unable to rename

之前也安装过hive,操作过无数,也没发现什么错误,今天因为之前安装的hadoop不能用了,不知道为什么,老是提示node 0,所以重新安装了hadoop和hive。安装完测试hive创建表也没发现什么错误,但是一旦执行create table tab_name as select * from (原表)的时候报如下的错:

Failed with exception Unable to rename: hdfs://hadoop:9000/tmp/hive-root/hi ve_2014-10-29_07-37-23_125_5663862080807255323/-ext-10001 to: hdfs://hadoop :9000/user/hive/warehouse/t1
FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec. MoveTask

 

网上找了很久,最后找到了,说是把hive-site.xml 中的hive.insert.into.multilevel.dirs的值改成true就可以。

  1. <property>  
  2.   <name>hive.insert.into.multilevel.dirs</name>  
  3.   <value>false</value>  
  4. </property>

Hive报错:Failed with exception Unable to rename