Click to See Complete Forum and Search --> : group permissions


Scott Howell
05-08-2002, 09:44 AM
I have Samba up and running under Mandrake 8.1, and have created a share called public. It is in folder /home/public and I would like to make this folder rwx for everyone in the group public. The problem I have is that when new files or folders are created in this share they by default do not give write or execute access to the group. How would I set this folder up so that any file or folder created in it will give rwx access to the user and group by default.

mychl
05-08-2002, 09:56 AM
I think you have to set the GID on that directory. I'm not sure how that would go exactly, but you know how with permissions you have 755, or 777... 3 numbers. Well there can be 4 numbers like 2755 or 2777, that first number will set the GID if you do it right.

HTH

OH, and also look at any of the umask options in your smb.conf file. Maybe if you change that appropriatly it will fix this as well...

Scott Howell
05-08-2002, 11:02 AM
OK, here is what I have tried :

Deleted everything out of the /home/public directory

Created a user public

Changed ownership of the /home/public directory (chown public :public /home/public)

Changed MOD of /home/public (chmod ug=rwx public and chmod ug+s public)

After completing all of this I logged on through Samba at a Win98 workstation as user1 and created a directory user1. When I look at the permissions in the linux machine for folder user1 it is owned by user1 and group public, and has rwx for the user and r-x for the group.

How do I make any new files or folders created have the write priveledge for the group by default?!?

Scott Howell
05-08-2002, 01:31 PM
Figured it out!!

It was a samba issue, and not a filesystem problem.

Added the lines :

create mask = 0770
directory mask = 0770

to the section for that share.

Thanks