Maybe someone can shed some light here as I'm confused.
I have this setup:
Server 1 (CentOS File Server)
-
Shared directory /file/to/www/share (owned by web-user:web-user)
-
Samba user "web-user" added
Server 2 (Debian Web Server)
-
Mounted //[server]/[share] to /mnt/www_share
-
Server has local user "web-user:web-user"
Now, (as root) I can access the share and Read/Write/Execute.
Though, no other users can Write (only Read/Execute).
I've tried setting the directories to 777, setting the umask in Samba to 000. I cannot mount to the share as non-root.
Any ideas?
Thanks
Best Answer
Unlike NFS (which, BTW, should have been your choice for Linux to Linux mounting), SMB doesn't automatically share user authorizations across the protocol - at least not without a complicated "Active Directory" setup.
What you probably want to do (other than change to a protocol that does share some user details, such as NFS), is to mount the directory using the required user permissions, using the
uid
andgid
options of themount
command orfstab
file.Use
man fstab
,man mount
(the smbfs section) andman smbmount
for more details.You might also be interested in investigating the
fmask
anddmask
options.