Linux Extensions with setuids on samba share

Unter TrueNAS core sometimes, when I mounted a SMB share under linux, the share was not only “single user”, but it was mounted like a NFS share, with UIDs and GIDs like normal.

With TrueNAS scale this never worked. How can I enable linux extensions with setuids - and how can I mount such a share under linux to use this?

(Please no discussion about using nfs and so on, I really want/have to use SMB in this case - but I did not find a guide or information about this in the manual)

I just found out, if I

  • enable SMB1 in the GUI
  • do net conf setparm GLOBAL "unix extensions" Yes as root on the TrueNAS shell
  • mount with mount.cifs -o vers=1.0

It works. Files do have the UID and GID they have on the server. This is what I need.

BUT: Using SMB1 is not a solution. ( https://sambaxp.org/fileadmin/user_upload/sambaxp2023-Slides/French_sXP23_SMB3.1.1_POSIX.pdf )

SMB3 unix extensions was formally added to Samba 4.20 (Electric Eel / 24.10) which is almost in beta, but support will be exposed via API / UI NET TrueNAS SCALE 25.04.

Hey!
I was under the assumption this would give us server inodes / ability to handle hardlinks from an SMB share, but I see no option for unix extensions, and my other linux server still logs “Autodisabling the use of serevr inode numbers”. Am I missing something here, or did it not make it into release?

Hey @awalkerix, sorry for pinging again on such an old thread, I cannot really find anything else on this topic. Were SMB3 Unix extensions added to the UI in 25.04, and if so, is there a guide / manual on where to access it? The only extensions I’ve found were the Apple ones in SMB settings.

They are still marked experimental upstream and so we haven’t exposed them yet.

1 Like

Thanks! Is there any opt-in for end users, or better to wait for (hopefully) next release?

Generally it’s better to wait until it’s stable and tested.

Hey! With 25-10 out, it appears to still not be exposed. Is this still being worked on? Is there any way for me to enable it?

No. It is still experimental upstream / not complete in this version.

smb3 unix extensions is disabled at share level, so those who want to use it for whatever reason are stuck making changes to util_smbconf.py. If it was disabled instead globally then it could be overridden with the cli smb_options by those who need it.

smb3 unix extensions is enabled by default in samba 4.23, shipped with TrueNAS 26.04, but is still hard-disabled at share level with no cli setting or smb_options to override.