Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Samba,ACL's and create mask

Posted on 2012-03-12
4
750 Views
Last Modified: 2012-03-22
Hi Experts,

I'm using samba -3.6.1 on Red Hat Enterprise Linux ES release 4 (Nahant Update 8) ,all seems ok. The issue im facing is as follows.

When ever a user creates a file via windows explorer the permissions assgined to the file are as follows

-rw-rwxr--+ 1 tom group2    0 Mar  9 10:02 testfile

drwxrwsr-x+ 2 bob group1 4096 Mar  9 10:38 testdir

Im ok with the directory permissions but would like the file permissions to be 644, following are my smb.conf ( create mask ) details


        create mask = 0644
        force create mode = 0644
        security mask = 0664
        force security mode = 0664
        directory mask = 2775
        force directory mode = 2775
        directory security mask = 2775
        force directory security mode = 2775

Also I have Linux ACL's on the shares for as the requirement called for some complexity.
so that only a few users in a group have access to the share.Could you experts help me with suitable mask that i need to use in smb,conf and a little explanation would be appreciated.

Thanks in advance
0
Comment
Question by:Peddu_bhanu
4 Comments
 
LVL 18

Expert Comment

by:TobiasHolm
ID: 37724821
Hi!

Have you tried:

        security mask = 0644
        force security mode = 0644

Also check the umask settings that the user has (typically 0022 which creates files of -rw-r--r-- and directories of drwxr-xr-x).

http://www.unix.com/tips-tutorials/19060-unix-file-permissions.html

Have you rebooted the Windows machine after you've made changes in the Samba setup? Might help.

Regards, Tobias
0
 
LVL 19

Accepted Solution

by:
Gabriel Orozco earned 500 total points
ID: 37740674
Use these

   create mode = 664
   directory mode = 2770
   force directory mode = 2770
   inherit permissions = yes

I have them running correctly on some servers.
0

Featured Post

Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If your business is like most, chances are you still need to maintain a fax infrastructure for your staff. It’s hard to believe that a communication technology that was thriving in the mid-80s could still be an essential part of your team’s modern I…
Join Greg Farro and Ethan Banks from Packet Pushers (http://packetpushers.net/podcast/podcasts/pq-show-93-smart-network-monitoring-paessler-sponsored/) and Greg Ross from Paessler (https://www.paessler.com/prtg) for a discussion about smart network …
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:

861 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question