Mapping user/permission between NAS share & Linux client mount
Posted: 19 May 2015 09:13
I just started using NAS4Free (9.3.0.2 [1391]), and although I'm pretty close, I can't seem to get this quite right:
On the NAS:
I've created a share where clients can store their backups:
...subfolders in the backups directory:
On the (Linux) client:
Backup software on John's and Sally's devices connect to the backups share using their 'john' and 'sally' credentials (respectively). John (an admin) is a member of the backup group, so he can see both his and Sally's backups. Sally is a temp, she is not a member of the backup group, so she only has access/visibility to the SallyPC subfolder and its contents.
In John's /etc/fstab file:
The problem:
When John's backup software writes to /mnt/backups/john-desktop:
Checking or unchecking Enable permission inheritance for this SMB share doesn't seem to make a difference. If I'm reading the documentation correctly, dir_mode and file_mode are ignored if the server does not support the CIFS Unix extensions.
Any help understanding this better will be greatly appreciated.
On the NAS:
I've created a share where clients can store their backups:
Code: Select all
drwxrwx--- 4 backup backup 4B May 18 11:57 backups
Code: Select all
drwxrwx--- 2 sally backup 27 Apr 22 08:50 SallyPC
drwxrwx--- 3 john backup 18466 May 18 13:32 john-desktop
Backup software on John's and Sally's devices connect to the backups share using their 'john' and 'sally' credentials (respectively). John (an admin) is a member of the backup group, so he can see both his and Sally's backups. Sally is a temp, she is not a member of the backup group, so she only has access/visibility to the SallyPC subfolder and its contents.
In John's /etc/fstab file:
Code: Select all
…
//nas-server/backups /mnt/backups cifs dir_mode=0755,file_mode=0644,iocharset=utf8,_netdev,nosetuids,rw,uid=john,gid=john,cred=/home/john/.nas-backup-cred 0 0
…
When John's backup software writes to /mnt/backups/john-desktop:
Code: Select all
Dirs: drwxr-xr-x …instead of… drwxrwx---
Files: -rw-r--r-- …instead of… -rw-rw----
Any help understanding this better will be greatly appreciated.