LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   How to configure rights on a Samba Share... (https://www.linuxquestions.org/questions/linux-networking-3/how-to-configure-rights-on-a-samba-share-732429/)

rizean 06-12-2009 05:07 AM

How to configure rights on a Samba Share...
 
What I am tring to do is give all users of group users rwe any files/directories of a samba share execpt for the top level.

Top Level cotains a number of folders and a readme file and should be r-e
Sublevel should be rwe including files/dir they did not create.

I'm am familure with chmod/chgrp but not sure how to do this.

billymayday 06-12-2009 10:46 PM

If you make sure all the users are members of the same group, then all levels down from the top should be 770 or 660, but make entries in the top level 550.

In fact, you probably want your directories 770 and your files 660.


So if the users are user1, user2, etc, in group users, do

chgrp -R users *

from the top level,

find ./ -type d -exec chmod -R 770 {} \;

and

find ./ -type f -exec chmod -R 660 {} \;

and finally

find ./ -type f -maxdepth 1 -exec chmod -R 440 {} \;

I haven't tested these, but they look about right.


All times are GMT -5. The time now is 04:47 AM.