Over a million developers have joined DZone.
{{announcement.body}}
{{announcement.title}}

Error Messages Do Lie..

DZone's Guide to

Error Messages Do Lie..

Error messages often correctly indicate that there's an issue, but they sometimes lie.

Free Resource

This is probably a trivial error. But when I was trying to deploy a file from the local file system to Hive, it kept giving the following error.

It was clear to me that the files indeed existed in the location /home/ec2-user/datacafe/. However, finally I realized that this is because the Hive client was unable to look beyond the Hadoop directory. That means, when I moved the files to /home/hadoop/datacafe, and pointed to them, Hive easily found them! Here /home/hadoop was the installation directory. So this is rather a simple permission issue than the more complicated issue I expected it to be.

21:19:09.380 [main] INFO  edu.emory.bmi.datacafe.hdfs.HiveConnector - Successfully written the output to the file, patients.csv
21:19:09.874 [main] ERROR edu.emory.bmi.datacafe.hdfs.HiveConnector - SQL Exception in writing to Hive Table: patients
org.apache.hive.service.cli.HiveSQLException: Error while compiling statement: FAILED: SemanticException Line 1:23 Invalid path ''../ec2-user/datacafe/patients.csv'': No files matching path file:/home/ec2-user/datacafe/patients.csv
    at org.apache.hive.jdbc.Utils.verifySuccess(Utils.java:231) ~[hive-jdbc-1.0.0.jar:1.0.0]
    at org.apache.hive.jdbc.Utils.verifySuccessWithInfo(Utils.java:217) ~[hive-jdbc-1.0.0.jar:1.0.0]
    at org.apache.hive.jdbc.HiveStatement.execute(HiveStatement.java:254) ~[hive-jdbc-1.0.0.jar:1.0.0]
    at edu.emory.bmi.datacafe.hdfs.HiveConnector.writeToHive(HiveConnector.java:119) ~[datacafe-server-1.0-SNAPSHOT.jar:?]
    at edu.emory.bmi.datacafe.hdfs.HiveConnector.writeToWarehouse(HiveConnector.java:60) [datacafe-server-1.0-SNAPSHOT.jar:?]
    at edu.emory.bmi.datacafe.hdfs.HiveConnector.writeDataSourcesToWarehouse(HiveConnector.java:50) [datacafe-server-1.0-SNAPSHOT.jar:?]
    at edu.emory.bmi.datacafe.impl.main.Initiator.initiate(Initiator.java:71) [datacafe-server-1.0-SNAPSHOT.jar:?]
    at edu.emory.bmi.datacafe.impl.main.Initiator.main(Initiator.java:39) [datacafe-server-1.0-SNAPSHOT.jar:?]
21:19:09.881 [main] INFO  edu.emory.bmi.datacafe.hdfs.HiveConnector - Successfully written the output to the file, slices.csv
21:19:10.097 [main] ERROR edu.emory.bmi.datacafe.hdfs.HiveConnector - SQL Exception in writing to Hive Table: slices
org.apache.hive.service.cli.HiveSQLException: Error while compiling statement: FAILED: SemanticException Line 1:23 Invalid path ''../ec2-user/datacafe/slices.csv'': No files matching path file:/home/ec2-user/datacafe/slices.csv
    at org.apache.hive.jdbc.Utils.verifySuccess(Utils.java:231) ~[hive-jdbc-1.0.0.jar:1.0.0]
    at org.apache.hive.jdbc.Utils.verifySuccessWithInfo(Utils.java:217) ~[hive-jdbc-1.0.0.jar:1.0.0]
    at org.apache.hive.jdbc.HiveStatement.execute(HiveStatement.java:254) ~[hive-jdbc-1.0.0.jar:1.0.0]
    at edu.emory.bmi.datacafe.hdfs.HiveConnector.writeToHive(HiveConnector.java:119) ~[datacafe-server-1.0-SNAPSHOT.jar:?]
    at edu.emory.bmi.datacafe.hdfs.HiveConnector.writeToWarehouse(HiveConnector.java:60) [datacafe-server-1.0-SNAPSHOT.jar:?]
    at edu.emory.bmi.datacafe.hdfs.HiveConnector.writeDataSourcesToWarehouse(HiveConnector.java:50) [datacafe-server-1.0-SNAPSHOT.jar:?]
    at edu.emory.bmi.datacafe.impl.main.Initiator.initiate(Initiator.java:71) [datacafe-server-1.0-SNAPSHOT.jar:?]
    at edu.emory.bmi.datacafe.impl.main.Initiator.main(Initiator.java:39) [datacafe-server-1.0-SNAPSHOT.jar:?]


Topics:
hadoop ,performance ,hive ,error log

Published at DZone with permission of Pradeeban Kathiravelu, DZone MVB. See the original article here.

Opinions expressed by DZone contributors are their own.

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}