我服务器上的所有 .php 文件突然导致内部服务器错误。
不知道有没有关系,更新yum的时候就开始了。
即使是空白的 .php 文件也会导致错误。我已经移动了我所有的网站内容并只尝试了一个空的 .php 文件,但它仍然给出了同样的错误。
也没有 .htaccess 文件。
我该怎么办? =/
(同一台服务器上的其他站点工作正常)
Apache 和 php 日志似乎没有更新。 Apache 的最后一个是从今天开始的,但没有与该问题相关的任何内容。 PHP 的最后一个来自 APRIL
更新
我刚刚发现每个域都有自己的 Apache 日志。
这是这个特定网站的内容
[Thu Jul 28 22:04:02 2011] [error] [client 173.245.56.24] Premature end of script headers: cgi_wrapper
[Thu Jul 28 22:04:02 2011] [error] [client 173.245.56.168] suexec policy violation: see suexec log for more details
[Thu Jul 28 22:04:02 2011] [error] [client 173.245.56.168] Premature end of script headers: cgi_wrapper
[Thu Jul 28 22:04:02 2011] [error] [client 103.22.200.144] suexec policy violation: see suexec log for more details
[Thu Jul 28 22:04:02 2011] [error] [client 103.22.200.144] Premature end of script headers: cgi_wrapper
[Thu Jul 28 22:04:02 2011] [error] [client 103.22.200.150] suexec policy violation: see suexec log for more details
[Thu Jul 28 22:04:02 2011] [error] [client 103.22.200.150] Premature end of script headers: cgi_wrapper
[Thu Jul 28 22:04:03 2011] [error] [client 173.245.56.168] suexec policy violation: see suexec log for more details
[Thu Jul 28 22:04:03 2011] [error] [client 173.245.56.168] Premature end of script headers: cgi_wrapper
[Thu Jul 28 22:04:04 2011] [error] [client 199.27.128.138] suexec policy violation: see suexec log for more details
[Thu Jul 28 22:04:04 2011] [error] [client 199.27.128.138] Premature end of script headers: cgi_wrapper
[Thu Jul 28 22:04:04 2011] [error] [client 103.22.200.246] suexec policy violation: see suexec log for more details
[Thu Jul 28 22:04:04 2011] [error] [client 103.22.200.246] Premature end of script headers: cgi_wrapper
最佳答案
我不确定,但有时它可能与文件权限有关。在我使用的网络主机上,如果权限未设置为 655,它将给出 505; 777 将给出 500 内部服务器错误。我的猜测是,在使用 YUM 的 PHP 分发更新中,他们做了类似的事情,但这只是一个猜测。简而言之,检查文件权限,如果它们不是 655,则尝试将它们更改为那个。
关于php - 任何导致内部服务器错误的 .php 文件,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/6865117/