I was trying to configure a folder to be shared using Samba, on a Redhat Enterprise Linux Server (RHEL) 6.
I did the usual things, like adding my user using "smbpasswd", adding a share config block to /etc/samba/smb.conf - and restarted "smb" and "nmb" services.
I could open the RHEL6 server from Windows7, and logon worked as expected.
But as soon as I tried to open any share on that RHEL6 samba server, I got an error message telling me something like "access denied":
(Sorry, only have the errormessage in German at the moment)
I've checked everything. Several times.Auf \\<servername>\<sharename> konnte nicht zugegriffen werden.
Sie haben keine Berechtigung für den Zugriff auf \\<servername>\<sharename>. Wenden Sie sich an den Netzwerkadministrator, um den Zugriff anzufordern.
[SOLUTION]
SELinux must be told to allow access to the shared folder:
Code: Select all
chcon -t samba_share_t <shared_foldername>
Details for setting up Samba on RHEL6, can be found in Edward Hurst's blog entry title "RHEL 6 for the Clueless: Samba Server (Updated)".