Can not R/W to subfolders in a share via Windows


Recommended Posts

I just purchased and installed Unraid.  I have a share named "Music" with multiple subfolders in which I have music categorized alphabetically.  Through windows I can do whatever I want in the main folder, but nothing in any of the subfolders.  Everything works fine if I move things around via the Krusader docker.  If I look at security in windows it is showing the owner as ServerName/nobody for all of the folders in the share.  The main folder allows full access to all other users (the share setting in Unraid is public).  The subfolders have full access to user Servername/nobody, but read/ execute for everyone else.  I have another folder for pictures where things are organized by date and I am going to want to be able to modify those pictures on other PCs and save them.  How do I change the permissions in Unraid for the subfolders to inherit the main share security settings?

 

I appreciate any help.

Link to comment

Let's see what the issue might be.  First login in a console ot terminal (PuTTY) session and run this command:

 

ls -al /mnt/user/Music
You should end with some like this:

drwxrwxrwx 1 nobody users       4096 Aug 17 18:18 ./
drwxrwxrwx 1 nobody users         58 Aug 17 16:42 ../
-rw-rw-rw- 1 nobody users    7726504 May 24 06:44 100-Magic_Act.mp4
-rw-rw-rw- 1 nobody users  169788268 Mar  2  2013 107D_OutdoorCupboard.mp4

If you don't see some of your music files go on down the directory tree by appending another directory/subfolder onto the end of the path.  In this case the nobody is the owner of the file and the users is the name for group allowed access with the group permissions.   If you don't have this, I would suggestion that you fix it with the Docker Safe New Perms Tool which is installed by the Fix Common Problems plugin.  This should fix the problem with the current files but the any new files will be wrong.  For this you will have to figure what of your Docker/plugin is generating these files and change its proprieties

Edited by Frank1940
Link to comment
  • 2 years later...

I have a similar issue. I'm having a share and created a subfolder through its user by an android app. This app is still able to create files inside this subfolder. Now I opened this folder with the same user through Windows and get an network error (Windows can not access ... You do not have permission...). Really strange 🤔

367615175_2020-05-0922_00_30.png.49a871dcd5a26533a66505d198fbc889.png

 

The user rights are looking good as well:

1160088478_2020-05-0922_07_31.png.92951e1edb4fc8cd0cbcf8a36d938262.png

 

 

And it becomes even more strange. I opened the share through its IP-address instead, entered the credentials, and are now able to open the subfolder without problems 🤪 

332744135_2020-05-0922_10_02.png.3af31fc1bba4704fe6c6374c1e7f648c.png

 

Seems to be windows related or what do you think?

 

EDIT: Ok, Windows Reboot solved the issue. Ok, thank you Windows 🙄

 

Edited by mgutt
Link to comment

I suspect that you have the 'attempt to login twice to the server' problem.  It is discussed quite thoroughly in this post:

 

EDIT:   If this is not the problem, be sure to read the next several posts to see if one of the other SMB peculiarities are to blame.

Edited by Frank1940
Link to comment
11 minutes ago, mgutt said:

I opened the share through its IP-address instead, entered the credentials, and are now able to open the subfolder without problems

4 minutes ago, Frank1940 said:

'attempt to login twice to the server' problem

Yes, going by IP vs servername makes Windows treat it as a different network computer and so different credentials can be used.

 

Even though Windows will sometimes prompt you for a different login because permission is denied, it won't actually use whatever you enter at the prompt since you are already logged in with different credentials.

 

Definitely a Windows quirk, since it treats other systems (even other Windows on the network) in just the same way.

 

 

Link to comment
16 minutes ago, trurl said:

Yes, going by IP vs servername makes Windows treat it as a different network computer and so different credentials can be used.

 

 

I did not enter different credentials. I used the same. Now, after restarting Windows both clients use the SMB alias again.

 

25 minutes ago, Frank1940 said:

I suspect that you have the 'attempt to login twice to the server' problem. 

It seems to be something related to this problem. Because the upload process through my smartphone has been interrupted. But I was able to restart the process without problems. The windows client is still able to open the folder and create files inside of it. It sounds like a bug for me. Something like "new login with same user = interrupt existing connection". I never had similar issues with my Synology NAS. Maybe a special setting needed for the SMB server?

 

I'll try to restart the windows client and try to open the network share again while the upload through the Android Client is running. Let's see if it happens again. EDIT: Hmm no. The upload is still running and windows can access and write as usual. Strange.

Edited by mgutt
Link to comment
Just now, trurl said:

Did you enter any credentials at all? If the current Windows username and password will work to access the share, then it won't even ask you to login.

Yes, I did. My windows login is completley different from the smb share on the Unraid server. My Unraid share username is "marc" and for the smb alias I enabled the checkbox to save this login. As you can see I did not save the login for the IP, too:

1412678445_2020-05-0922_53_00.png.612f1494b49fec27501ce1c225eaa69e.png

 

Link to comment
  • 2 weeks later...
5 hours ago, mgutt said:

I really don't know why but /EF had other permissions:

 

1073324596_2020-05-2300_56_59.png.21f73a5ea51970af5d5490932fb947c5.png

Those are not the normal permissions for an Unraid system.   You normally expect to see the user/group to be nobody/users and not root/root.   It sounds as if you copied the files/folders using a tool local to the Unraid server that has not set the standard permissions.   Having them set to root/root will stop any access via the network working correctly.

 

The permissions can be corrected by running Tools>>New permissions against the share in question.

 

Link to comment
7 hours ago, itimpi said:

It sounds as if you copied the files/folders using a tool local to the Unraid server that has not set the standard permissions.

 

Yes I used rclone to fetch the files from the old NAS through SFTP. I'm not sure, but as I moved a new movie to /EF by using Tiny File Manager, that could be the reason of the permission change.

Edited by mgutt
Link to comment
  • 1 year later...
On 5/9/2020 at 10:13 PM, mgutt said:

And it becomes even more strange. I opened the share through its IP-address instead, entered the credentials, and are now able to open the subfolder without problems 🤪 

 

Seems to be windows related or what do you think?

 

EDIT: Ok, Windows Reboot solved the issue. Ok, thank you Windows 🙄

 

 

I just wanted to add, that what you describe in the a.m. first sentence is a "regular" Windows behaviour.

Simply said, accessing the same fileserver, once by its name and then by its IP address are counted as two different connections for Windows.

And this is the reason why you had to enter your credentials one more time and why, in this case, it solved half of your problem.

 

Regards, DaKarli. 👍

Edited by DaKarli
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.