Our Community is getting an upgrade! To get everything ready for the relaunch, we’ll be placing the site in read-only mode starting September 21st.
We really appreciate your understanding while we get things set up behind the scenes. Catch up on all the exciting details about the move here.
Need help or have questions? Drop us a line at [email protected]
Created 01-05-2016 02:21 PM
Problem loading data to table in this tutorial
http://hortonworks.com/hadoop-tutorial/how-to-process-data-with-apache-hive/
This command
<code>LOAD DATA INPATH '/user/admin/Batting.csv' OVERWRITE INTO TABLE temp_batting;
produces error
H110 Unable to submit statement. Error while compiling statement: FAILED: HiveAccessControlException Permission denied: user [admin] does not have [READ] privilege on [hdfs://sandbox.hortonworks.com:8020/user/admin/elecMonthly_Orc] [ERROR_STATUS]
I created both user/admin and temp/admin folders. I used hdfs superuser to make admin owner of file, folder, and even parent folder. I gave full permissions in HDFS. and this is clearly shown in Ambari. Error persists.
Can anyone help? Thanks
Created 02-03-2016 04:17 PM
It was because when I thought I was creating an elecMonthly_Orc file, actually I created an elecMonthly_Orc folder with several files three files: _SUCCESS, part-r-r-00000-1a0c14e3-0dd0-42db-abc7-7f655a02f634.orc ... and another similar orc files. The files within the elecMonthly_Orc directory were owned by Hive, and that's why the permissions error.
Resolved by using command line as superuser hdfs:
hadoop fs -chown admin:admin /user/admin/elecMonthly_Orc/*.*
Now I just have to figure out how to recombine Orc files in Hive!
Created 01-05-2016 03:24 PM
Is temp_batting an external or internal table? My assumption is it's an internal table and thus when you load data in path, it's trying to move the data in /apps/warehouse/database(default)/temp_batting and the admin user doesn't have permissions to move the file.
Can you please try running:
hdfs dfs -chmod -R 777 /user/admin/elecMonthly_Orc
and then trying to run your load data inpath command?
Created 02-02-2016 07:28 PM
@Aidan Condron are you still having issues with this? Can you accept best answer or provide your own solution?
Created 02-03-2016 04:17 PM
It was because when I thought I was creating an elecMonthly_Orc file, actually I created an elecMonthly_Orc folder with several files three files: _SUCCESS, part-r-r-00000-1a0c14e3-0dd0-42db-abc7-7f655a02f634.orc ... and another similar orc files. The files within the elecMonthly_Orc directory were owned by Hive, and that's why the permissions error.
Resolved by using command line as superuser hdfs:
hadoop fs -chown admin:admin /user/admin/elecMonthly_Orc/*.*
Now I just have to figure out how to recombine Orc files in Hive!
Created 02-03-2016 04:19 PM
@Aidan Condron can you convert your response to answer and we can mark it as best answer?
Created 03-08-2016 02:30 AM
Hey guys. The tutorial mentioned above has been updated and is also compatible with the latest Sandbox HDP 2.4. It addresses the issue of permissions. Here is the link: http://hortonworks.com/hadoop-tutorial/how-to-process-data-with-apache-hive/
When you a chance, can you go through the tutorial on our new Sandbox?