[Samba] chmod g+s not working over cifs

steve steve at steve-ss.com
Fri Jun 7 08:56:05 MDT 2013


Hi
I've had this problem since 3.0.9 an I've now reproduced it on 4.0.6,
4.0.7 git and 4.1.0 pre1

Summary: if I chmod g+s a shared folder, the file created therein are
not group owned.

Here is the original post from March which didn't get a reply:


Version 4.0.5-GIT-9ec44d4
Single DC and fileserver running the samba binary.

Hi
I have a share called shared:
[shared]
         path = /home/shared
         read only = No

I set the ACL:
setfacl -R -m g:staff:rw,d:g:staff:rw /home/shared

This is what it looks like:
getfacl shared
# file: shared
# owner: root
# group: staff
# flags: -s-
user::rwx
group::rwx
group:staff:rw-
mask::rwx
other::---
default:user::rwx
default:group::rwx
default:group:staff:rw-
default:mask::rwx
default:other::---

The file listing looks OK:
drwxrws---+  3 root  staff  4096 Mar 29 10:05 shared

Problem:
Files created from Linux cifs mounted or W7 clients are group 'Domain 
users', the primary group of the user, not 'staff' as the g+s should 
give. Files created in the share on the DC are correctly assigned to 
group 'staff'.

Question:
How do I get files created in the share 'shared' to be group owned by 
group 'staff'?

Cheers,
Steve.




More information about the samba mailing list