Hey guys,
I have a server running Centos 7 with 2 hdds in redundancy. I set up the hdds a while back with a bunch of stuff on them, and then today I reinstalled Centos on the server. I configured samba, and from my windows machine I can look at the folder, but if I try accessing the subfolders I get the error "Windows cannot access \\hostname. You do not have permission to access. Contact your network administrator." I'm not sure what's different because I think I configured it the same as it was before. I've set permissions to 0777 and ownership to nobody:nobody. I am able to access the folders from the server, so it is possible, but I still want to be able to do it from windows.
Any help would be appreciated!
smb.conf:
[global]
workgroup = WORKGROUP
security = user
netbios name = samba
max protocol = SMB3
security = user
map to guest = bad user
dns proxy = no
passdb backend = tdbsam
printing = cups
printcap name = cups
load printers = yes
cups options = raw
[homes]
comment = Home Directories
valid users = %S, %D%w%S
browseable = No
read only = No
inherit acls = Yes
[printers]
comment = All Printers
path = /var/tmp
printable = Yes
create mask = 0600
browseable = No
[print$]
comment = Printer Drivers
path = /var/lib/samba/drivers
write list = @printadmin root
force group = @printadmin
create mask = 0664
directory mask = 0775
[Plex]
path = /Plex
browseable = yes
writable = yes
guest ok = yes
guest only = yes
read only = no
create mode = 0777
directory mode = 0777
Access denied for Samba Share
-
- Posts: 1521
- Joined: 2014/05/21 20:16:00
- Location: Central New York, USA
Re: Access denied for Samba Share
May not be the answer but at the very least set all those "777" permissions back to 775 - there's absolutely no reason anyone who connects should be able to edit your files! Then I'd set the owner back to (whoever it was:whoever it was).
I'm very poor with samba, but I wonder if making the affected folders browseable does that.?.
I'm very poor with samba, but I wonder if making the affected folders browseable does that.?.
Re: Access denied for Samba Share
1.
[global]
workgroup = WORKGROUP
security = user
netbios name = samba
#max protocol = SMB3
2.
Temporaly disable SELinux and restart Samba:
As root in terminal:
#Show status SELinux
getenforce
#Temporaly disable SELinux (enable SELinux back: setenforce 1)
setenforce 0
#restart Samba
systemctl restart smb
[global]
workgroup = WORKGROUP
security = user
netbios name = samba
#max protocol = SMB3
2.
Temporaly disable SELinux and restart Samba:
As root in terminal:
#Show status SELinux
getenforce
#Temporaly disable SELinux (enable SELinux back: setenforce 1)
setenforce 0
#restart Samba
systemctl restart smb