Created on 12-20-2019 07:57 PM - last edited on 12-20-2019 08:46 PM by ask_bill_brooks
I am logged into Ambari with 'admin' user.
Then I navigated to File View >> 'user' directory >> Create a New Folder >> Enter name of folder and click on 'Add' button.
But I am getting a server message: -
Permission denied: user=admin, access=WRITE, inode="/user":hdfs:hdfs:drwxr-xr-x
How can I provide write permission on user directory to write something or add a folder to it. Request to community to help me. Thanks.
Created on 12-20-2019 09:08 PM - last edited on 12-20-2019 09:27 PM by ask_bill_brooks
The "/user" directory permission and ownership is shows as "hdfs:hdfs:drwxr-xr-x"
Which means it can be written only by superuser "hdfs". However in ambari you have logged in as "admin" user which is NOT superuser "hdfs". So you may have to change the ownership of this dir (Which is not recommended) so that 'admin' user can create a directory inside it ....
But if you want to perform the directory creation inside "/user" via file view only then you can try this:
1. In Ambari UI Navigate to
"admin" → "Manage Ambari" → Users → "Add Users" Button
2. Create a user with name "hdfs" (you can choose your own desired password for this user and specify in the UI form)
3. You can create this user as Cluster Admin ...etc based on the type needed in the "User Access" section. Similarly you can make that user as Ambari Admin if needed. (But this is up to your requirement)
4. Now give the View Access permission to this user "hdfs"
"admin" → "Manage Ambari" → Views → "AUTO_FILES_INSTANCE" (click on "edit" button)
5. At the end of the "AUTO_FILES_INSTANCE" view definition you will find section named as "Permissions" please add user "hdfs" there.
6. Now try to login to a freshly opened browser as "hdfs" user and then you should be able to create Folders inside "/user" directory using File View.
.
Later you can disable the "hdfs" user account anytime in the Ambari UI.
Created on 12-20-2019 09:08 PM - last edited on 12-20-2019 09:27 PM by ask_bill_brooks
The "/user" directory permission and ownership is shows as "hdfs:hdfs:drwxr-xr-x"
Which means it can be written only by superuser "hdfs". However in ambari you have logged in as "admin" user which is NOT superuser "hdfs". So you may have to change the ownership of this dir (Which is not recommended) so that 'admin' user can create a directory inside it ....
But if you want to perform the directory creation inside "/user" via file view only then you can try this:
1. In Ambari UI Navigate to
"admin" → "Manage Ambari" → Users → "Add Users" Button
2. Create a user with name "hdfs" (you can choose your own desired password for this user and specify in the UI form)
3. You can create this user as Cluster Admin ...etc based on the type needed in the "User Access" section. Similarly you can make that user as Ambari Admin if needed. (But this is up to your requirement)
4. Now give the View Access permission to this user "hdfs"
"admin" → "Manage Ambari" → Views → "AUTO_FILES_INSTANCE" (click on "edit" button)
5. At the end of the "AUTO_FILES_INSTANCE" view definition you will find section named as "Permissions" please add user "hdfs" there.
6. Now try to login to a freshly opened browser as "hdfs" user and then you should be able to create Folders inside "/user" directory using File View.
.
Later you can disable the "hdfs" user account anytime in the Ambari UI.