Permissions for Samba & NFS with Windows, Mac, and Linux clients

Status
Not open for further replies.

rmccullough

Patron
Joined
May 17, 2018
Messages
269
I took a look at Methods For Fine-Tuning Samba Permissions, but it is really much deeper than I think I need. I think a sticky with a handful of common scenarios and how to setup your permissions would be extremely helpful.

See signature for setup. I can currently access several SMB shares from a Windows 10 machine right now. I have some trouble accessing them from Mac, but let's start with Windows for now. I can access all of the files, and I can write new files to the directories I have, but I can't edit existing files. I suspect this is because I created them with some other permissions and there is ACL stuff in there.

What I would like is to have a Dataset that I can expose via SMB and NFS. I would like to be able to authenticate to it using a user who I have already configured on FreeNAS. This user is a member of groups that own the directories/files in the Dataset. Further, how can I reset the permissions/ownership/acls of the files in that Dataset?
 
Joined
Jul 3, 2015
Messages
926
Personally I would create an admin account on the box user = admin group = admin. Then make admin the user and group owner of the dataset. Make sure your dataset is Windows and that permissions are Windows. Shared the dataset via Windows SMB shares. Then from your Windows 10 machine map that drive and connect as your admin user. Then remove the 'everyone' from the share (unless you want that) and add your user or group that wants permissions to the share and give them full control (or something appropriate).
Apple users should be able to connect to this share no problems.

Its never a good idea to share one dataset with two different protocols therefore I'd suggest you have an SMB dataset\share and a separate NFS dataset\share which would use UNIX permissions and be a UNIX dataset.
 

rmccullough

Patron
Joined
May 17, 2018
Messages
269
@Johnny Fartpants I think this worked for me (with some tweaks). I could not add my local windows account, but I was able to add my FreeNAS user, and then mount the drive with that user and then write to files. Thanks!
 

rmccullough

Patron
Joined
May 17, 2018
Messages
269
I wanted to add, what is the best setup if I would like to share files across multiple client operating systems (Windows, Mac, Linux)? I would like to use NFS for Mac & Linux as my understanding is that NFS is multi-threaded so it has the potential for better performance. That said, I don't know that it would work that well for Windows. Am I stuck using SMB for everything because Windows needs it?
 
Joined
Jul 3, 2015
Messages
926
I wanted to add, what is the best setup if I would like to share files across multiple client operating systems (Windows, Mac, Linux)? I would like to use NFS for Mac & Linux as my understanding is that NFS is multi-threaded so it has the potential for better performance. That said, I don't know that it would work that well for Windows. Am I stuck using SMB for everything because Windows needs it?
SMB is always the way when you have Windows, Mac and Linux machines wanting to share the same data. Unless you are running 10Gb network to your desktops then SMB should be plenty fast enough.
 
Status
Not open for further replies.
Top