I have a Dataset, lets call it tank.
there are 5 Folders inside tank:
/mnt/tank/data/folder1 to /mnt/tank/data/folder5
I want to create an SMB share “streaming_share”:
read only
displays only folder1 and folder2
accessible from user “streaming”
what I did:
at first I tried to add two paths to the share but didn’t know how.
I thought to do it with a correct user right, but am not skilled enough.
third way would be by creating a new folder and 2 subfolders and links folder 1 and 2 to the new folder with mount --bind /mnt/tank/data/folder1 /mnt/tank/data/streaming_folder/folder1
please what would be the most straight forward method of doing that.
(besides creating streaming_folder and than moving folder1 and folder2 there)
thank you.
I have bee using truenas core for ~2 years and now am using scale for ~2 years.
Shares only have a single path. Typically the way you’d do what you want is configure permissions such that “streaming” user can only read folder1 and folder2.
You set permissions for a share (which is a dataset), including all folders in there. Mind the terminology.
You can have one read-only share for user “streaming”, with as many folders in there as you want.
Or, if other users are to have access to one folder but not the other, you can have two distinct shares with different permission sets, and then “streaming” has to mount two shares to have the two sets of files.
Filesystem permissions are defined on a per-file basis.
You can use the ACL editor on a Windows client for instance to disable inheritance on a given directory then modify its ACL to suit your needs.
Our APIs are also path-based and so can change permissions anywhere in /mnt, but it’s still not implemented in UI (since it’s more of a file manager feature).
I think screenshots of your datasets and how you have your sharing set up would help us see what you currently have setup. We are kind of guessing by your description.
Below are screenshots from my CORE system
Shay is parent and BU2 is the child dataset I have setup for SMB sharing. Everything inside is shared the same.
Thanks for all the answers,
The solution was more or less “set correct access rights”
In the process i discovered that i had a bad access right set up in general and than managed to screw up access rights so that i needed to redo most of my shares. But I think i got it now.