permissions on VFAT partitions

Indulis Bernsteins indulis.b at au1.ibm.com
Sun Dec 23 20:13:09 GMT 2001


>I'm running RH7.1 and Samba 2.2.2 . I would like to offer a VFAT
>partition on the server  hard drive for universal read-write access. I
>mount the partition in fstab with
>
>/dev.hda5    /sys    vfat    defaults,rw,uid=1001,gid=1001    0 0
>
>It mounts fine and shows up on the Windows 98 machine and can be opened.
>I can't write to it however.

OK what I did to make this exact thing work on my system was to create a 
new group on my system called "user" (=gid 502)

in my /etc/fstab I made the entry for /dev/hda5 look like

/dev/hda5    /sys    vfat    uid=500,gid=502,umask=002

(umask=2 means permissions=775=rwxrwxr-x  ie write to people in the owning 
group as well as the owner)

And I set up my remote user to belong to group "user".

The only other trick is that if you have been playing around with the 
user's credentials (user id, groups the user belongs to), you need to 
disconnect/reconnect to samba as it is like logging on to a normal UNIX 
shell, the user's group list and other credentials are picked up at login 
time. So if you have not logged in/out after making some changes, then any 
changes you have made to the user's group id or user id (uid) since the 
login don't have any effect on the samba client...(I discovered this after 
a Windows reboot fixed my problem).

Apart from that, I have just defined the remote user on linux as a normal 
user with a name matching what is shown under 
"settings-network-identification-computer name" in windows.  Password 
matching the logon password on the windows network client.

It *does* work!!! So don't give up on it!

(And if you really get stuck you can set the smb daemon up to give you a 
detailed trace of what it is doing as it tries to fulfil your requests. 
DOesn't tell you about the login/logout trick though!)

Luck!

Indulis

Indulis Bernsteins
Senior Systems Architect
IBM Australia
-------------- next part --------------
HTML attachment scrubbed and removed


More information about the samba mailing list