Find the answer to your Linux question:
Results 1 to 4 of 4
Hi, I don't know how to create samba(Version 3.6.5) share for 2 groups with permissions: 1 GROUP: create files, read any files, but don't change/delete any files 2 GROUP: full ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Oct 2012
    Posts
    2

    Question SAMBA, share for 2 groups


    Hi,

    I don't know how to create samba(Version 3.6.5) share for 2 groups with permissions:
    1 GROUP: create files, read any files, but don't change/delete any files
    2 GROUP: full access: create, read, change, delete any files
    It's possible to use acl or 2 shares.


    Can somebody help me?
    Thank you

  2. #2
    Super Moderator Roxoff's Avatar
    Join Date
    Aug 2005
    Location
    Nottingham, England
    Posts
    3,916
    Take a look at the man page for smb.conf.

    You should be able to do this with a single share. You need to set your filesystem permissions so that each group gets the relevant access then, in the share declare a 'read list' and a 'write list' for the share. Something a bit like this:

    Code:
    [share name]
    ...
    read list = @group_with_read_perms
    write list = @group_with_write_perms
    ...
    This will not work with security=share if you're running samba 3.

    You can do this with ACLs too (and it's probably better to do it that way), but it's more complex.
    Linux user #126863 - see http://linuxcounter.net/

  3. #3
    Just Joined!
    Join Date
    Oct 2012
    Posts
    2
    Hi, Roxoff!
    Thank you for your answer.
    But I need 2 groups with write access.
    Group1 can only create and read files, but not change/delete files( create mask = 0444)
    Group2 can create/read/change/delete any files( create mask = 0666)

    And read list - This is a list of users that are given read-only access to a service.

  4. $spacer_open
    $spacer_close
  5. #4
    Super Moderator Roxoff's Avatar
    Join Date
    Aug 2005
    Location
    Nottingham, England
    Posts
    3,916
    I had a read down some of the ACL stuff for samba. It seems to point ACL stuff at Unix-like filesystem permissions, i.e. the rwx settings. Using these standard permissions, you don't have the control to separate create and edit permissions.

    It might be possible using two shares and a combination of inherited ownership for the share and force user/force group. But I can't think of a scenario that would work for what you want. Perhaps someone with a bit more expertise than I have can help?
    Linux user #126863 - see http://linuxcounter.net/

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •