Archives of Support Questions (Read Only)

This is an archived board for historical reference. Information and links may no longer be available or relevant
Announcements
This board is archived and read-only for historical reference. To ask a new question, please post a new topic on the appropriate active board.

permission denied while creating table in hive

avatar

I am creating a table through script , my script is placed at /home/yarn and i am executing the script through yarn user, but i am getting permission error :

user= yarn access= write permission denied

1 ACCEPTED SOLUTION

avatar
Master Mentor

@Anurag Mishra

Can you please share the complete error that you are getting? Also little detail about what your script is doing?

It might be the HDFS directory where the user "yarn" is trying to write and does not have write permission. If that is the case then you might want to give write permission to the "yarn" user to that HDFS directory.

# su - hdfs -c "hdfs dfs -chmod 777 /PATH/WHERE/YARN/USER/IS/WRITING
(OR)
# su - hdfs -c "hdfs dfs -chown -R yarn:hadoop  /PATH/WHERE/YARN/USER/IS/WRITING

.

View solution in original post

1 REPLY 1

avatar
Master Mentor

@Anurag Mishra

Can you please share the complete error that you are getting? Also little detail about what your script is doing?

It might be the HDFS directory where the user "yarn" is trying to write and does not have write permission. If that is the case then you might want to give write permission to the "yarn" user to that HDFS directory.

# su - hdfs -c "hdfs dfs -chmod 777 /PATH/WHERE/YARN/USER/IS/WRITING
(OR)
# su - hdfs -c "hdfs dfs -chown -R yarn:hadoop  /PATH/WHERE/YARN/USER/IS/WRITING

.