Web服务器中的“权限被拒绝”(Mediatemple上的CentOS)

我已经做了另一个关于gitolite的文章,我已经解决了,但是这开始使我恶化。 我可以看到我的文件有读取权限,但我的错误日志继续产生"Permission denied""Failed opening ... for inclusion""Unknown: Failed opening required"错误。

在网站上, mchat.php显示一个空白页面。 我发现错误报告,但没有出现。

 [Sun Oct 31 17:21:05 2010] [error] [client 76.95.40.61] PHP Warning: include(./mchat.php) [<a href='function.include'>function.include</a>] : failed to open stream: Permission denied in /var/www/vhosts/website .com/httpdocs/index.php on line 267 [Sun Oct 31 17:21:05 2010] [error] [client 76.95.40.61] PHP Warning: include() [<a href='function.include'>function.include</a>]: Failed op ening './mchat.php' for inclusion (include_path='.:') in /var/www/vhos ts/website.com/httpdocs/index.php on line 267 [Sun Oct 31 17:21:07 2010] [error] [client 79.105.140.245] PHP Fatal e rror: Unknown: Failed opening required '/var/www/vhosts/website.com/ httpdocs/mchat.php' (include_path='.:') in Unknown on line 0 

正如你所看到的,我收到了三个不同的错误。 其中一个是造成其他人的吗?

ls -l返回:

 -rw-r--r-- 1 git psacln 8824 Oct 31 22:53 index.php drwxr-xr-x 2 git psacln 4096 Oct 31 22:53 mchat -rw-r--r-- 1 git psacln 38964 Nov 1 00:02 mchat.php 

谁能帮忙?

SELinux可能已启用。 要么用

 chcon -R -t httptd_sys_content_t <folder> 

要么

 setenforce 0 

如果您不使用SELinux,那么您可以考虑永久禁用它。 虽然学习/使用它总是一个好主意。