Avatar of Jayock

asked on 

Linux Samba file POSIX Permissions with OSX Leopard Access

I have a samba server set up on an FC8 server, with OSX Leopard and WinXP clients.  I have set the force create mode and force directory mode to the permissions I want.  The WinXP clients transfers, including created files and copied files get these POSIX permissions set correctly, but the OSX Leopard clients do not on copy.  It looks like the Leopard client is reading the attributes from the original file, and chmod the copied file after it is copied to preserve permissions.  This is messing up my linux group access to some file on the samba share.  

Temporarily, I have set up a chmod -R 0770 /path/ in crontab to run every minute as a temporary work around.  I would like to find a solution to make samba either a) disable client chmod or b) force all files to remain 0660 and all directories 0770.  Any ideas?
LinuxServer SoftwareMac OS X

Avatar of undefined
Last Comment
Avatar of e-tsik
Flag of Israel image

Blurred text
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
Avatar of Jayock


I have that already. Which works great, except for the OSX leopard client which executes a chmod after the create happens. So even though the file is created with the desired 0770 permissions, the client changes it afterwards to preserve the permissions of the original file.
Avatar of e-tsik
Flag of Israel image

If the OSX client makes a chmod after the file is created then that isn't really a Samba issue.
Does your OSX client connect via NFS?

If you want to prevent this problem from happening via NFS, then you might want to check the "all_squash" option to the exportfs file - this will cause all users to connect anonymously making each user able to read other users' files even if they chmod them to 0600.

If you use
force user = root ; (or some other user)
force group = root; (or some other group)

Then that makes everyone able to read and write to these files even after they are chmod'ed

Linux is a UNIX-like open source operating system with hundreds of distinct distributions, including: Fedora, openSUSE, Ubuntu, Debian, Slackware, Gentoo, CentOS, and Arch Linux. Linux is generally associated with web and database servers, but has become popular in many niche industries and applications.

Top Experts
Get a personalized solution from industry experts
Ask the experts
Read over 600 more reviews


IBM logoIntel logoMicrosoft logoUbisoft logoSAP logo
Qualcomm logoCitrix Systems logoWorkday logoErnst & Young logo
High performer badgeUsers love us badge
LinkedIn logoFacebook logoX logoInstagram logoTikTok logoYouTube logo