preserving UNIX file permissions (BUG#508)

samba-bugs at samba-bugs at
Tue Oct 7 14:31:47 GMT 1997

> Hi, I have a small household network and I am providing access to home
> directories on the server via Samba, so that we can edit files from the
> other PCs even if they are in win95.  One annoying thing however is that
> every time a file is edited and then saved it's permissions are set to
> whatever the share's create mask is set to.

Yep, Windows applications often create a temporary file then rename it.
This means permissions info is lost.
> This wouldn't be such a problem, but it seems that even with create mask =
> 777 I can't get any files to be created with group or other execute
> permission.  This is playing havoc for people who want to edit their perl
> CGI scripts from Windows, as they then have to log into the server anyway
> to chmod them back to 755 or whatever.
> Is there a way to fix this?  Is it obvious, and I just haven't read the
> right bits of the manual?  Or am I misunderstanding some basic principle
> of Samba?

Have a look at the "map hidden", "map system" and "map archive" options
in the smb.conf man page.

If you turn all 3 off then you will find that you will start getting the other
x bits back.

Samba uses these execute bits to map these DOS attributes.


More information about the samba mailing list