[ 
https://issues.apache.org/jira/browse/HIVE-2419?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Zhuoluo (Clark) Yang updated HIVE-2419:
---------------------------------------

    Attachment: HIVE-2419.1.patch

This is an annoying problem, especially for new hive users. We have fixed the 
problem in our internal version of hive by simply create the 
hive.metastore.warehouse.dir during the semantic analysis phase.
                
> CREATE TABLE AS SELECT should create warehouse directory
> --------------------------------------------------------
>
>                 Key: HIVE-2419
>                 URL: https://issues.apache.org/jira/browse/HIVE-2419
>             Project: Hive
>          Issue Type: Bug
>            Reporter: David Phillips
>         Attachments: HIVE-2419.1.patch
>
>
> If you run a CTAS statement on a fresh Hive install without a warehouse 
> directory (as is the case with Amazon EMR), it runs the query but errors out 
> at the end:
> {quote}
> hive> create table foo as select * from t_message limit 1;
> Total MapReduce jobs = 1
> Launching Job 1 out of 1
> ...
> Ended Job = job_201108301753_0001
> Moving data to: 
> hdfs://ip-10-202-22-194.ec2.internal:9000/mnt/hive_07_1/warehouse/foo
> Failed with exception Unable to rename: 
> hdfs://ip-10-202-22-194.ec2.internal:9000/mnt/var/lib/hive_07_1/tmp/scratch/hive_2011-08-30_18-04-36_809_6130923980133666976/-ext-10001
>  to: hdfs://ip-10-202-22-194.ec2.internal:9000/mnt/hive_07_1/warehouse/foo
> FAILED: Execution Error, return code 1 from 
> org.apache.hadoop.hive.ql.exec.MoveTask
> {quote}
> This is different behavior from a simple CREATE TABLE, which creates the 
> warehouse directory.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to