请求超过了10个内部redirect的限制

所以这里是错误

[Mon Sep 30 00:09:53 2013] [error] [client 66.249.66.205] 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. [Mon Sep 30 00:09:53 2013] [debug] core.c(3120): [client 66.249.66.205] r->uri = /home/mysitecom/domains/mysite.com/public_html/index.php [Mon Sep 30 00:09:53 2013] [debug] core.c(3126): [client 66.249.66.205] redirected from r->uri = /home/mysitecom/domains/mysite.com/public_html/index.php [Mon Sep 30 00:09:53 2013] [debug] core.c(3126): [client 66.249.66.205] redirected from r->uri = /home/mysitecom/domains/mysite.com/public_html/index.php [Mon Sep 30 00:09:53 2013] [debug] core.c(3126): [client 66.249.66.205] redirected from r->uri = /home/mysitecom/domains/mysite.com/public_html/index.php [Mon Sep 30 00:09:53 2013] [debug] core.c(3126): [client 66.249.66.205] redirected from r->uri = /home/mysitecom/domains/mysite.com/public_html/index.php [Mon Sep 30 00:09:53 2013] [debug] core.c(3126): [client 66.249.66.205] redirected from r->uri = /home/mysitecom/domains/mysite.com/public_html/index.php [Mon Sep 30 00:09:53 2013] [debug] core.c(3126): [client 66.249.66.205] redirected from r->uri = /home/mysitecom/domains/mysite.com/public_html/index.php [Mon Sep 30 00:09:53 2013] [debug] core.c(3126): [client 66.249.66.205] redirected from r->uri = /home/mysitecom/domains/mysite.com/public_html/index.php [Mon Sep 30 00:09:53 2013] [debug] core.c(3126): [client 66.249.66.205] redirected from r->uri = /home/mysitecom/domains/mysite.com/public_html/index.php [Mon Sep 30 00:09:53 2013] [debug] core.c(3126): [client 66.249.66.205] redirected from r->uri = /home/mysitecom/domains/mysite.com/public_html/index.php [Mon Sep 30 00:09:53 2013] [debug] core.c(3126): [client 66.249.66.205] redirected from r->uri = /images/2013/02/600x376_0.076827001313237200_pixnaz_ir_1.jpg 

我怎么才能find什么东西呢?

它似乎是一个循环index.php,除了最后一个是一个图像,最有可能链接在我的一个页面(而不是索引)

我使用的codeigniter这是一个mvc框架,一切都进入低谷index.php文件….所以有点难以理解它出错了。

显然这与htaccess有关(这在一些博客中已经提到)

这里是我的htacc …基本上它从所有的链接中删除index.php,没有什么不寻常的

 <IfModule mod_rewrite.c> RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule ^(.*)$ index.php/$1 [L] </IfModule> <IfModule !mod_rewrite.c> # If we don't have mod_rewrite installed, all 404's # can be sent to index.php, and everything works as normal. # Submitted by: ElliotHaughin ErrorDocument 404 index.php </IfModule> AddType image/x-windows-bmp bmp 

我有一个专用的服务器

您需要添加一个exception,以便您不要将index.php重写为index.php?/index.php 。 (另外,你确定你想要一个/之后?

这是一个RewriteCond来停止这个循环:

 RewriteCond %{REQUEST_URI} != /index.php/ 

它应该在RewriteRule之前插入。

循环的原因是,每次在.htaccess文件中触发重写时,apache都会创build一个内部子请求。 这是为什么要避免重写.htaccess的许多原因之一。 所以,如果你有访问你的httpd.conf把重写在那里。 如果你不能把你的重写放在configuration中,如果你真的必须使用.htaccess文件,那么确保添加一个打破循环的条件。