This is the old XigmaNAS forum in read only mode,
it will taken offline by the end of march 2021!



I like to aks Users and Admins to rewrite/take over important post from here into the new fresh main forum!
Its not possible for us to export from here and import it to the main forum!

Windows 7 "normal" user has no access ...

CIFS/SMB network sharing.
Forum rules
Set-Up GuideFAQsForum Rules
Post Reply
gabier
Starter
Starter
Posts: 23
Joined: 08 Dec 2014 16:41
Status: Offline

Windows 7 "normal" user has no access ...

Post by gabier »

Hello everybody,

I can't have Windows users access to nas4free files. Of course I have enabled SAMBA/CIFS.

On NAS4Free :
2 users gabriel and ggadmin, both in group "admin" with path "/mnt/RAID1A"
A raid array RAID1A with the following directories:
/mnt/RAID1A/ggadmin/backup/
All these directories belong to ggadmin and have permissions 770.

Now, on the client Windows 7:

2 users gabriel and ggadmin. ggadmin is a Windows administrator but gabriel is not.

When logged as "ggadmin", windows explorer gives access to all files, and the security tab in the directories properties show clearly entities which have "total control" of these directories : admin(UnixGroup\admin), super gg(Nas4Free\ggadmin) and gabriel(NAS4FREE\gabriel)

But when logged as "gabriel" (normal user, not administrator), Windows explorer does not display the files under the backup directory and the security tab is quite reduced when compared to the previous one. The entities displayed are "admin (Unix Group\admin)" and "super gg(NAS4FREE\ggadmin)" but they have no permission at all. "gabriel" is not displayed.
If I try to modify the permissions, either by adding the user "gabriel" or by giving total control to "ggadmin", it aborts with an error message "Access denied ..." (probably because the asking user is not a windows administrator.

How can I manage to have both users, especially the non administrator one, to have full access to the NAS4Free files ???
I am looking either for a direct solution or a user manual of Samba/CIFS in order to understand what is going on.

:) gabier
Dell 8300 computer with NAS4Free 10.2.0.2- RAID1 2TB
Dell 8900 Desktop (Windows 10) Cygwin 2.3.0

noclaf
experienced User
experienced User
Posts: 116
Joined: 08 Dec 2013 12:37
Status: Offline

Re: Windows 7 "normal" user has no access ...

Post by noclaf »

I'm beginner, but I think you can't change permission of N4F directories from W7.
My advice would be to check what users / groups are set up in your N4F and what ownership is set up for directories in N4F.

E.g. my setup is following (maybe too complicated, but as I said, I'm beginner) :
my main username noclaf is in group wheel
using chown I recursively set up ownership of the whole share to noclaf:wheel
using chmod I recursively set up full access for owner, group and no right for others

Now if I want to anybody else to access the share, I'll simply create his username in N4F and add him to group wheel. And I can block him fom accessing any folder by removing group rights for that directory (e.g. this directory will be accessible only for the user-owner = noclaf and not for the group owner = wheel)

gabier
Starter
Starter
Posts: 23
Joined: 08 Dec 2014 16:41
Status: Offline

Re: Windows 7 "normal" user has no access ...

Post by gabier »

noclaf wrote:I'm beginner, but I think you can't change permission of N4F directories from W7.
My advice would be to check what users / groups are set up in your N4F and what ownership is set up for directories in N4F.
Thank you noclaf for your reply. I checked the permissions all along the different file paths, and made a few changes and back in order to better understand what is going on.
I still think it is not only a permission problem, but also a problem of mapping of users by the file interface (SMB?).
As I explained earlier The users in N4F and in the Windows client are the same, say userA and userB, but their groups are different:
In N4F NuserA and NuserB both belong to the same admin group, NuserA owns all files. With permissions 770 both users should have full access to all files, because they are in the same group.
But in Windows when WuserA or WuserB asks for access to the files in N4F, then Windows component SMB or CIFS has to find out if this user is a regular n4f user and, if yes, determine his rights.
In my case he results suggest that Windows conclusions are :
1.WuserA is indeed NUserA and has the same rights
2. WuserB is NuserB but it has not the same rights, probably because it is not an administrator.
I can verify this because with permissions 770 WuserB has no rights but with permissions 777 he has all rights and can access all files. This means that SMB has decided that WuserB's rights are not the rights of the group, but the rights of "others".
Well this is not what I want.
So my question is : what should I do in SMB to give to Windows WuserB the group's rights as the rights of N4F NuserB ? How can I map the rights of a N4F user to the rights of a windows user ?
I hope I was clear.
:) gabier
Dell 8300 computer with NAS4Free 10.2.0.2- RAID1 2TB
Dell 8900 Desktop (Windows 10) Cygwin 2.3.0

gabier
Starter
Starter
Posts: 23
Joined: 08 Dec 2014 16:41
Status: Offline

Re: Windows 7 "normal" user has no access ...

Post by gabier »

Well well!
It turns out maybe noclaf is right.
I thought that all my files were 770, or at least 740. But to be sure, using chmod -R, I reset all the files to 770. And surprise, I can browse all files from the windows clients.
I still do not understand how Windows finds out what Unix user is the asking Windows user (the only obvious mean is the name). But the result is what is important.
My files are imported in NAS4Free using Rsync. I do not know what permissions Rsync sets, maybe some mixture of source permissions in Windows. My conclusion is that it would be wise to run a chmod command on all imported files if I want them to be correctly browsed in the future.
:) gabier
Dell 8300 computer with NAS4Free 10.2.0.2- RAID1 2TB
Dell 8900 Desktop (Windows 10) Cygwin 2.3.0

noclaf
experienced User
experienced User
Posts: 116
Joined: 08 Dec 2013 12:37
Status: Offline

Re: Windows 7 "normal" user has no access ...

Post by noclaf »

Glad it works. :)

Post Reply

Return to “CIFS/SMB (Samba)”