阿帕奇2.4 - 请求超过了10内部重定向的限制,由于可能的配置错误 [英] Apache 2.4 - Request exceeded the limit of 10 internal redirects due to probable configuration error

查看:4460
本文介绍了阿帕奇2.4 - 请求超过了10内部重定向的限制,由于可能的配置错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在Windows Server 2008 R2企业运行的Apache 2.4(64位)和PHP 5.4.15,并已经注意到,在Apache的错误日志中的以下错误:

I'm running Apache 2.4 (64bit) and PHP 5.4.15 on windows Server 2008 R2 Enterprise and have noticed the following error in the Apache error log:

AH00124: Request exceeded the limit of 10 internal redirects due to probable configuration error. Use 'LimitInternalRecursion' to increase the limit if necessary. Use 'LogLevel debug' to get a backtrace.

我有字preSS运行的多站点安装,我认为错误是从错误中htaccess的重写来了。

I have a multisite install of WordPress running and I think the error is coming from an error in the htaccess rewrites.

看着这篇文章: <一href="http://stackoverflow.com/questions/1611506/request-exceeded-the-limit-of-10-internal-redirects-due-to-probable-configuratio">Request超过10个内部重定向的限制,由于可能的配置错误。?

他们建议,以取代这样的:

They suggest to replace this:

# BEGIN Wordpress
<IfModule mod_rewrite.c>
  RewriteEngine On
  RewriteBase /
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteRule . /index.php [L]
</IfModule>
# END WordPress

与这片code,礼貌斯科特·杨:

with this piece of code, courtesy of Scott Yang:

<IfModule mod_rewrite.c>
   RewriteEngine On
   RewriteBase /
   RewriteCond %{REQUEST_FILENAME} !-f
   RewriteCond %{REQUEST_FILENAME} !-d
   RewriteRule ^(.+)$ /index.php/$1 [L,QSA]
</IfModule>

不过,我的字preSS htaccess的看起来有点不同的,所以我不只是想取代我的code,以防万一我无意中替换我需要的东西。

However, my WordPress htaccess looks a little different so I dont just want to replace my code just in case I inadvertently replace something that I need.

下面是我的htaccess的:

Here is my htaccess:

# BEGIN WordPress
<IfModule mod_rewrite.c>
Options +FollowSymLinks -MultiViews
Header set Access-Control-Allow-Origin "*"
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
# add a trailing slash to /wp-admin
RewriteRule ^wp-admin$ wp-admin/ [R=301,L]
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ - [L]
RewriteRule ^(wp-(content|admin|includes).*) $1 [L]
RewriteRule ^(.*\.php)$ $1 [L]
RewriteRule . index.php [L]
</IfModule>
# END WordPress

任何人都可以提出什么,我需要改变吗?

Can anyone suggest what I need to change?

推荐答案

你进入循环最有可能是由于这些规则:

You're getting into looping most likely due to these rules:

RewriteRule ^(.*\.php)$ $1 [L]
RewriteRule ^(wp-(content|admin|includes).*) $1 [L]

只是把它注释掉,然后再试一次在一个新的浏览器。

Just comment it out and try again in a new browser.

这篇关于阿帕奇2.4 - 请求超过了10内部重定向的限制,由于可能的配置错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆