1

I have a new Synology NAS (DS1621+), and have begun integration into my home network. I'm having some problems using it with my Linux hosts. I can mount the NAS, but the permissions (as seen from Linux) are not what I want them to be. I'm under the impression that ownership & permissions can be "mapped" from the NAS to my Linux clients, but it's unclear to me how this is done. My Linux hosts are all Debian-based units, and file services provided by the Synology NAS are via SMB. From Linux, I use the cifs-utils suite (mount -t cifs ...) to mount the shares.

I've contacted Synology, and was surprised to learn:

1: Synology does not provide tech support to "command line" users.
2: Synology claimed their SMB implementation is proprietary, and do not provide any (useful) documentation on the interface.

I suspect that Synology's implementation is not that far off mainstream, but after some trial-and-error, I'm still having "permissions issues". Also, the mount.cifs manual has many options whose purpose and effect are vague to me.

Are there any Linux tools available that can help identify how the various options and parameters in mount.cifs affect permissions as seen from the Linux client's perspective? I'd like to eliminate as much of the trial-and-error as possible.

I'm interested in using SMB instead of NFS because I've heard more negatives on NFS than I have SMB.

I have created the users on the Synology side and added them to the SMB config there.

EDIT: 2022-07-12; More reading, findings

The variables which seem to be in play are:

  1. the state of the Linux implementation of the "Unix Extensions" to SMB, and the version on my client machine
  2. the state of the server's (Synology's) implementation of SMB/Samba
  3. the state of the server's (Synology's) implementation of the "Unix Extensions"

In an effort to improve the quality of this question, I've attempted to define these variables in the context of my question:

  1. Re the state of the Linux implementation of the "Unix Extensions":
$ mount.cifs --version mount.cifs version: 6.11 # NOTE1: Unix Extensions are enabled by default per man mount.cifs # NOTE2: see also 'modinfo cifs' 
  1. Re server (Synology) version of SMB/Samba:
$ ssh admin@SynologyNAS-1 /$ samba --version Version 4.10.18 /$ uname -srm Linux 4.4.180+ x86_64 
  1. Re server (Synology) version of the "Unix Extensions"

    I'm at a loss on how to do this, so I tried smbclient:

$ smbclient \\\\SynologyNAS\\rpi_share -U=pi Enter WORKGROUP\pi's password: Try "help" to get a list of possible commands. smb: \> help ? allinfo altname archive backup blocksize cancel case_sensitive cd chmod chown close del deltree dir du echo exit get getfacl geteas hardlink help history iosize lcd link lock lowercase ls l mask md mget mkdir more mput newer notify open posix posix_encrypt posix_open posix_mkdir posix_rmdir posix_unlink posix_whoami print prompt put pwd q queue quit readlink rd recurse reget rename reput rm rmdir showacls setea setmode scopy stat symlink tar tarmode timeout translate unlock volume vuid wdel logon listconnect showconnect tcon tdis tid utimes logoff .. ! smb: \> ? posix HELP posix: turn on all POSIX capabilities smb: \> posix Server doesn't support UNIX CIFS extensions. smb: \> ? chmod HELP chmod: <src> <mode> chmod a file using UNIX permission smb: \> chmod test-touch-4B.txt 666 Server doesn't support UNIX CIFS calls. ... 

2022-07-12; Conclusions & Revised Questions?

The above results with smbclient suggest that with respect to SMB/CIFS, my client software is up to speed, but my shiny new Synology NAS is far behind the curve.

My original question now becomes, "Are these results accurate; is there a more conclusive or accurate method to determine the status of a product when the vendor refuses any information on it?"

For those with similar questions, I can only offer this:

In my case: I mount using Synology user pi credentials. Doing so leaves my Linux user pi unable to write to the mounted share - despite the fact that Synology user pi had been given R&W privileges in the Synology DSM. I found that adding the uid=pi and gid=pi options to my mount -t cifs command, at least enabled the Linux user pi to write to the SMB share on the Synology server. Why this works I will have to leave for others to answer.

Further Reading:

  1. The SMB UNIX Extensions Wiki
  2. CIFS VFS - Protocol extensions to the Common Internet File System for better POSIX file I/O semantics
  3. A Search: what are the "Unix Extensions" for SMB/CIFS/Samba?.
  4. Samba version 4.3 or newer supports SMB 3.1.1
  5. Linux cifs mailing list
  6. mount.cifs and mount.smb3 are nearly the same; ref man mount.cifs - which is also the manual for mount.smb3.
  7. The SMB3-Linux Wiki
  8. Are SMB POSIX Extensions Same As SMB Unix Extensions?... Apparently not
  9. CIFS Protocol Extensions Update, fm 2006 (This has been YEARS in the making)
  10. A Tour through the CIFS Protocol Extensions and Linux CIFS client, fm. 2008.
  11. SMB3 POSIX Extensions Phase 2 ... what is next? (fm. 2020)
  12. The video of #10 above
  13. The Linux kernel user’s and administrator’s guide » CIFS (note: more verbiage by Steve French)
  14. What Is SMB Protocol and Why Is it a Security Concern?
  15. Server Message Block - Wikipedia
4
  • Maybe you just found one of the cons for SMB... Try NFS. Commented Jul 8, 2022 at 15:50
  • BTW you can enable ssh on NAS and try to see how they configure samba Commented Jul 8, 2022 at 16:45
  • Excellent, well written question with NO answer two year later. NFS has it lot of problems as well. Synology still ships a deprecated Linux to this day. It is a shame Linux client are left behind. I should have never bought Synology NAS. Commented Dec 8, 2024 at 22:35
  • @MathieuJ. said, "I should have never bought Synology NAS." Synology does some things well, other things NOT well; overall I'm also negative on Synology. But what are the alternatives? Commented Dec 10, 2024 at 18:51

0

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.