This is the old XigmaNAS forum in read only mode,
it will taken offline by the end of march 2021!



I like to aks Users and Admins to rewrite/take over important post from here into the new fresh main forum!
Its not possible for us to export from here and import it to the main forum!

Mapping user/permission between NAS share & Linux client mount

CIFS/SMB network sharing.
Forum rules
Set-Up GuideFAQsForum Rules
Post Reply
StuPiddaz
NewUser
NewUser
Posts: 3
Joined: 19 May 2015 06:31
Status: Offline

Mapping user/permission between NAS share & Linux client mount

Post by StuPiddaz »

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:

Code: Select all

drwxrwx---   4 backup  backup     4B May 18 11:57 backups
...subfolders in the backups directory:

Code: Select all

drwxrwx---  2 sally   backup     27 Apr 22 08:50 SallyPC
drwxrwx---  3 john    backup  18466 May 18 13:32 john-desktop
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:

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
    …
The problem:

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----
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.

arxaios
Starter
Starter
Posts: 19
Joined: 29 Apr 2015 11:19
Status: Offline

Re: Mapping user/permission between NAS share & Linux client mount

Post by arxaios »

Check the Permissions you gave on the mount points where you have your shares in .!

Go to menu Disks -> Mount Point . (See if they are in conflict with your Shares...!!)

Good luck.
P.S. If your are using Linux Clients better use NFS Shares instead.

StuPiddaz
NewUser
NewUser
Posts: 3
Joined: 19 May 2015 06:31
Status: Offline

Re: Mapping user/permission between NAS share & Linux client mount

Post by StuPiddaz »

Check the Permissions you gave on the mount points where you have your shares in .!

Go to menu Disks -> Mount Point . (See if they are in conflict with your Shares...!!)
I neglected to mention that I'm using ZFS, so my mount points (if that's the correct terminology) are defined in Disks|ZFS|Datasets|Dataset, and owners and permissions are set the way I want them...

Owner: backup
Group: backup
Mode:

Code: Select all

Owner  = r w x
Group  = r w x
Others = - - -
P.S. If you are using Linux Clients, better use NFS Shares instead.
Actually, I'm doing both. I'd prefer to use NFS for all my linux VMs and workstation, but some other devices in the house can only deal with SMB shares.

KUbo_0
NewUser
NewUser
Posts: 4
Joined: 23 May 2014 21:13
Status: Offline

Re: Mapping user/permission between NAS share & Linux client mount

Post by KUbo_0 »

have the same problem on my both n4f 9.3 servers.
mount permission checked.. seems like it samba's issue, because wincsp shows all right

User avatar
mel
NewUser
NewUser
Posts: 9
Joined: 26 May 2015 05:52
Location: Russia
Status: Offline

Re: Mapping user/permission between NAS share & Linux client mount

Post by mel »

Use Auxiliary parameters Services|CIFS/SMB|Share|Edit

Code: Select all

create mask = 0660
directory mask = 0770
N4F 10.3.0.3 - Pilingitam (revision 2898) on ASUS M5A78L-M/USB3 | AMD FX-4300 | 16GB of ECC RAM | 9x3TB WD Red in RaidZ2

Post Reply

Return to “CIFS/SMB (Samba)”