Linux – Changing File and Folder Ownership from Root

chownfile-permissionslinuxnfs

I created a folder structure as root and now need to transfer ownership to an ordinary user.

This question is linked to this one – Providing permission to specific user to access NFS share

I have a folder /srv/app-share that needs to be visible/writeable to user1

I tried (as root):

root@server [/]# chown -R user1:user1 /srv/

But that did not work.

Best Answer

What messages did you get, any errors? Did you try without the last slash in /srv/ so that it specifically indicates the directory itself?

As simple test confirms it works my side, however I did not specify a group:

root@server [/]# chown -R user1: /srv/

Perhaps there is no group called 'user1' in your case? run groups | grep user1 and see if you have that user group.

Related Question