I am trying to set permissions on a Samba share mounted with vers=3.0, but it does not work (with vers=2.1 or vers=2.0 also issue is present).
As per SMB3-Linux cifsacl option is needed for setting the permission bits, but if that option is used the folder does not mount:
# mount -t cifs //server.lan/aaditya /home/roaming/SERVER/aaditya -o 'username=aaditya,domain=server.lan,password=mypass,cifsacl,vers=3.0,nobrl,mfsymlinks,sfu,uid=1274545246,gid=1274544641'
mount error(95): Operation not supported Refer to the mount.cifs(8)
manual page (e.g. man mount.cifs)
Is there something that I am missing?
It works with vers=1.0 which has unix extensions but trying to avoid it as SMB 2.0+ seems to have much better performance and design (here and here).
Client details:
# mount.cifs -V mount.cifs version: 6.4 # uname -srm Linux 4.10.0-38-lowlatency x86_64 # lsb_release -ird Distributor ID: Ubuntu Description: Ubuntu 16.04.3 LTS Release: 16.04
Server details:
$ uname -srm Linux 4.4.0-97-generic x86_64 $ lsb_release -ird Distributor ID: Ubuntu Description: Ubuntu 16.04.3 LTS Release: 16.04 $ samba --version Version 4.6.7-Ubuntu
Answers:
Thank you for visiting the Q&A section on Magenaut. Please note that all the answers may not help you solve the issue immediately. So please treat them as advisements. If you found the post helpful (or not), leave a comment & I’ll get back to you as soon as possible.
Method 1
Samba does not yet support UNIX extensions for SMB v2.0+. It is being worked on. [lists.samba.org, 10/2017]
They say that when UNIX extensions will be finalized, the Samba implementation is ”not going to allow clients to create ’real‘ symlinks on the server – only SMB-followable symlinks. Allowing clients to create real server symlinks as in SMB1 UNIX extensions has been a long-term security disaster.“ [same thread]
All methods was sourced from stackoverflow.com or stackexchange.com, is licensed under cc by-sa 2.5, cc by-sa 3.0 and cc by-sa 4.0