LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 12-26-2013, 03:29 PM   #1
anon091
Senior Member
 
Registered: Jun 2009
Posts: 1,795

Rep: Reputation: 49
Files/folders getting wrong permissions even though they're foced through samba


I have a server we use to host samba shares, and quite regularly we're seeing files/folders with incorrect permissions, they're getting drwxr-xr-x instead of drwxrwxrw-.

In our smb.conf, we have force user and force group set, and those are correct even on the problem folders. But we also set these two settings in smb.conf:
create mask = 0764
directory mask = 0776

I have a hunch that the machines added the folders with the incorrect permissions are OSX machines, so not sure if since that is based on Unix it's doing something funky with samba?

Any ideas what to check or what other settings to configure in smb.conf to prevent this from happening?
 
Old 12-26-2013, 11:37 PM   #2
deep27ak
Senior Member
 
Registered: Aug 2011
Location: Bangalore, India
Distribution: RHEL 7.x, SLES 11 SP2/3/4
Posts: 1,195
Blog Entries: 4

Rep: Reputation: 221Reputation: 221Reputation: 221
Quote:
Originally Posted by rjo98 View Post
I have a server we use to host samba shares, and quite regularly we're seeing files/folders with incorrect permissions, they're getting drwxr-xr-x instead of drwxrwxrw-.

In our smb.conf, we have force user and force group set, and those are correct even on the problem folders. But we also set these two settings in smb.conf:
create mask = 0764
directory mask = 0776

I have a hunch that the machines added the folders with the incorrect permissions are OSX machines, so not sure if since that is based on Unix it's doing something funky with samba?

Any ideas what to check or what other settings to configure in smb.conf to prevent this from happening?
I believe that is happening due to the default umask set value which is 0755

The share which you have configured in smb.conf, is that accessible by public or a list of valid users?
 
Old 12-27-2013, 07:31 AM   #3
anon091
Senior Member
 
Registered: Jun 2009
Posts: 1,795

Original Poster
Rep: Reputation: 49
The share is accessible via public/guest, as we do a force user and force group for this share in particular. What is a umask?
 
Old 12-29-2013, 01:58 AM   #4
deep27ak
Senior Member
 
Registered: Aug 2011
Location: Bangalore, India
Distribution: RHEL 7.x, SLES 11 SP2/3/4
Posts: 1,195
Blog Entries: 4

Rep: Reputation: 221Reputation: 221Reputation: 221
You can follow the below link to know about umask

http://www.cyberciti.biz/tips/unders...lue-usage.html
 
Old 12-30-2013, 08:18 AM   #5
anon091
Senior Member
 
Registered: Jun 2009
Posts: 1,795

Original Poster
Rep: Reputation: 49
Thanks. I never even heard of that before. Any thought as to why OSX machines would use this rather than what's in smb.conf while when PCs connect to the share they get those forced masks from the samba config?
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Samba permissions - randomly unable to rename move or save files and folders rebelscum1 Linux - Server 0 08-22-2013 05:44 PM
Samba new files and folders permissions pjgm Linux - Server 1 08-24-2011 04:23 PM
Samba can create new files and folders but access denied in any new folders k.king Linux - Networking 2 01-15-2006 06:14 AM
Permissions of new folders through samba doctorwebbox Linux - Networking 9 08-10-2004 12:46 AM
files&folders permissions under SAMBA share shani Linux - Software 2 11-20-2003 11:48 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 06:45 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration