[Samba] Strange Samba permissions on vfat (fat32) volume

Michael Heydon michaelh at jaswin.com.au
Tue Jun 17 03:26:15 GMT 2008


Tomas Mackevicius wrote:
> I'm running Samba on Ubuntu server. I know, perhaps it is not related with Ubuntu Server 8.04, but rather
> with Samba itself, but I thought perhaps someone has similar
> experience...
>
>   
Actually I don't think it has much to do with samba either.
>
> I have a couple of shares on Samba on a vfat (fat32) volume. As
> everybody knows Linux permissions does not work on vfat, except on
> mount folder where vfat partition is mounted. I though that is really
> not a minus, but a plus if you want to create share for 10-15 users,
> because then it's not necessary to mess with all those permissions. 
>   
You could achieve the same thing under a fully functional fs and 
wouldn't run into problems like this :)
> <snip>
>
>
> Normal file:
> -rwxrwxrwx 1 root server1  6158201 1999-05-05 21:36 Alex Gopher - Super Disco.mp3
>
>
> Bad file:
> -r-xr-xr-x 1 root server1 2568192 2001-10-04 16:52 Bjork - All Is Full Of Love.mp3
>
>   
I think this is your problem.
>
> I realized that some of the "bad" files where copied to vfat partition
> from CD drive (when this HDD was still on a windows PC). So the logical
> thinking would suggest, that those files have Read Only mark (which is
> usually given to all files that are copied from CD). Knowing this I
> tried to play with smb.conf options:
>
>
>
>         delete readonly = Yes
>
>         map readonly = No / Yes
>   
That isn't how it works, the map read only maps the client's read only 
value to the server's unix permissions, what you are interested in is 
how the unix permissions are mapped to the file system's read only flag.
>
> I didn't get any results. I tried to change other map options but with
> no results either. Permissions were not intact. My Only idea is that
> somehow Samba is interpreting Read-Only flag and that affects the file
> permissions.
>   
It isn't samba as you demonstrated with your ls output above, it is 
occuring at the file system level.
>
> I would really appreciate any comments or ideas. Here are the settings of my share:
>
>         available = Yes
>   
Default value.
>         browseable = Yes
>   
Default value.
>         read only = No
>
>         follow symlinks = No
>   
Symlinks can't exist on a fat fs.
>         hide dot files = Yes
>   
Default value.
>         delete readonly = Yes
>
>         case sensitive = No
>   
Default value.
>         preserve case = Yes
>   
Default value.
>         map archive = Yes
>   
Tries to change unix permissions, which wont work on a fat fs.
>         map system = No
>   
Tries to change unix permissions, which wont work on a fat fs.
>         map hidden = No
>   
Tries to change unix permissions, which wont work on a fat fs.
>         map readonly = No
>   
Tries to change unix permissions, which wont work on a fat fs.
>         guest ok = No
>   
Default value.
>         oplocks = No
>
>         level2 oplocks = No
>
> Thanks to all.
>
>   
None of that should have any effect on the problem at hand, but it is 
kind of pointless to define a heap of options to their default value.

*Michael Heydon - IT Administrator *
michaelh at jaswin.com.au <mailto:michaelh at jaswin.com.au>




More information about the samba mailing list