SELinux and Samba shares
EPKPhoto — 16 June 2007 - 9:40pm
Well, this little gem just wasted several hours of my life. For future reference, if a strange problem occurs that involves file or network access or modification, be sure to consider SELinux as the source of the issue.
In this case, I was setting up some Windows shares via Samba on a Fedora 7 system. I already had another Fedora 7 system with several SMB shares that functioned just right, so I was mostly copying the configuration to this second system. When I tried to connect to the shares from Windows XP, Mac OS X, or another Linux computer, the file browser connected, displayed the shares, but threw up an error when trying to open any of the shares.
On Mac OS X, the error was a nondescript "Error -43." Windows XP said something to the effect of not having permission to access the share. Another Fedora system said that I did not have permission to access the share, or it had been deleted.
After thinking a bit, I finally came to the realization that the only difference in the configuration of those two Fedora 7 systems was SELinux. I had disabled SELinux on the system with the functioning SMB shares. So instead of simply disabling SELinux on the new system, I opened the SELinux Management app (system-config-selinux). Under the Boolean section, I found several entries for Samba. After enabling to allow those options, the SMB shares functioned perfectly.
Post new comment