How to share the root of the dataset in Samba?

allanonmage

Dabbler
Joined
Aug 20, 2023
Messages
31
When I'm browsing to my smb share, it's \\truenas\maindataset\<blah> Is there some way to remove "maindataset" from the path such that any folders that are in the dataset are just \\truenas\<blah>? My NAS will be 1 giant storage on my network, and I'd prefer to have 1 SMB share with all the folders in it. As it is now, there's this extra directory looking thing in the path, which is weird because everything is in it. In Shares, I've shared "/mnt/testvdev/maindataset".

In Windows, each share shows up as a separate folder after the server, so now that I think about it, I'm not sure if this is doable on any platform.
 
Joined
Oct 22, 2019
Messages
3,641
Don't share the root dataset of any pool.

Don't try to modify the permissions of the root dataset. (The GUI prevents you, but the command-line does not.)

I know it seems awkward, but you need at least one child dataset underneath the root dataset of a pool.
 

allanonmage

Dabbler
Joined
Aug 20, 2023
Messages
31
Don't share the root dataset of any pool.

Don't try to modify the permissions of the root dataset. (The GUI prevents you, but the command-line does not.)

I know it seems awkward, but you need at least one child dataset underneath the root dataset of a pool.
I'm not following. I used the GUI to set up the share.
 
Joined
Oct 22, 2019
Messages
3,641
Then you might be confusing some terms, or it's the way you worded your thread title?

Do you mean that you don't want to see the "share name" display in your Windows File Explorer location bar?

That's not the dataset name you're seeing. That's the "share name". You can have multiple shares on the same server. By default, if you don't write your own custom share name, it will simply use the name of the dataset (or root path) of the share.

So for example, you can create an SMB share that points to /mnt/mypool/media. This will, by default, use the "share name" of "media". But you can always type in your own share name, such as "puppies-are-cute".

Now you can browse it from File Explorer by visiting \\truenas\puppies-are-cute

It will still show you the same folder contents.
 
Top