Windows Samba file owners permissions


Recommended Posts

As seen in the below screenshot whenever I make a file it gets created with my 'windowspc' user which is a user created through UNRAID and then used to access my share through windows. However, this means that when I want to view the file from another user I don't have permission to access it. Anyway to allow all users to access this?
image.png.3c2da810933c0dcaede6f64f44936f69.png
 

Link to comment

On the Shares page of the GUI you'll see two columns, labelled SMB and NFS. For that particular user share (backups) it is behaving as though it is set to Public for NFS sharing and Private for SMB sharing. If that's the case you need to change the SMB sharing to Public.

 

59745046_ScreenShot2021-05-31at00_32_10.png.8c84173bae9fd04e1a199d790e3d8d67.png

 

Edited by John_M
Added screenshot
Link to comment

From the online help:

 

Quote

Security modes:

  • '-' -- user share is not exported and unavailable on the network
  • Public -- all users including guests have full read/write access (open access)
  • Secure -- all users including guests have read access, write access is set per user (limited access)
  • Private -- no guest access at all, read/write or read-only access is set per user (closed access)

 

Link to comment
10 hours ago, JRascagneres said:

image.png.3c2da810933c0dcaede6f64f44936f69.png
 

 Look at the '+' sign at the end of the permissions.  That should normally not be there.    You can find more information about this if you google :

 

what is "+" in drwxrwxrwx+

 

I do know that running either the   Docker Safe New Perms  or the    New Permissions  scripts found on the   Tools      tab will set the owner, group and permissions correctly on the Share.    You only want to run either of these utilities on the directory/folder that has the issue.  What I am not sure is if either one will fix that "+" attribute...

 

Question:  When you mapped the drive on your Windows computer, did you play with the permissions in the Properties on the mapped drive?  

Edited by Frank1940
Link to comment

In the GUI go to Settings -> Users. Add a user to Unraid for each Windows user you have. If you make the names and passwords identical to how they are in Windows, you'll save yourself a lot of grief.

 

In the GUI go to Shares. Create a new user share. In SMB Security Settings make it Private or Secure, depending on whether you want to allow guest read access. In SMB User Access set up for each user whether he has read and/or write access.

 

If you want guest write access, just make it Public instead.

 

Each file/directory is owned by its creator and additional read/write permissions for other users are stored in ACLs.

  • Like 1
Link to comment

@John_M, Interesting.  I have never seen this and I do use 'Secure' Shares.   I have no doubt that is because of the way that I actually implement its use.

 

Most of my shares are actually 'Secure'.  As I basically use my two Unraid servers in a 'write once-read many' type of operation.  In fact, these Secure Shares have no users assigned to them to prevent direct write access to them using SMB.  (This basically prevents Malware from having write access from a Windows client!)  But it does allows 'Public' access to able to read the files.   (New files are added by having the cache drive being shared as 'Public' Disk Share.  Files are transferred to the cache drive and placed into a folder on that drive that mimics the Share that the file is to end in.  Unraid's Mover will then transfer the file to the Secure Share on the array.) 

 

 

Link to comment
12 hours ago, Frank1940 said:

Most of my shares are actually 'Secure'.

 

That's a clever use of the options available to you. I haven't done a lot of testing but I think the ACLs are set up when a second user is given permissions to access a share in the SMB User Access section (ie. when Unix permissions are no longer sufficient). They are simply applied to the top level directory and propagated to its contents. I think the majority of users settle for Public shares because they are the default, they usually "just work" and because Windows networking is already more fraught with difficulties than it needs to be.

  • Thanks 1
Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.