LiteSpeed Technologies
Download Download     Blog Blog     Wiki Wiki     Forum Forum     Store     Contact Contact    

Go Back   LiteSpeed Support Forums > LiteSpeed Web Server > General > [solved] External loop redirection after an htaccess update

Reply
 
Thread Tools Display Modes
  #1  
Old 01-03-2013, 11:16 AM
Cremas2 Cremas2 is offline
New Member
 
Join Date: Jan 2013
Posts: 3
Question [solved] External loop redirection after an htaccess update

In my Apache error.log I get thousands of this error:

Code:
2013-01-02 20:46:44.582 [INFO] [50.18.21.225:48281-1#APVH_example.com] [REWRITE] detect external loop redirection with target URL: /index.html, skip.
2013-01-02 20:46:44.582 [INFO] [50.18.21.225:48276-1#APVH_example.com] [REWRITE] detect external loop redirection with target URL: /index.html, skip.
I have such a .htaccess file:

Code:
<IfModule mod_rewrite.c>
    RewriteEngine On

    RewriteCond &#37;{HTTP_HOST} ^www\.(.*)$ [NC]
    RewriteRule ^(.*)$ http://%1/$1 [R=301,L]

    RewriteCond %{HTTP_USER_AGENT} "Somebot|Otherbot" [NC,OR]
    RewriteCond %{HTTP_USER_AGENT} "Anotherbot|Theotherbot|Badbot" [NC]
    RewriteCond %{REQUEST_URI} !(\/mypages|\/otherpages) [NC]
    RewriteRule ^(.*)$ index.html? [R=301,L]

    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteRule ^(.*)$ index.php [QSA,L]
</IfModule>
If I comment out this block, I don't get any error. But I need that for mysite.

Code:
RewriteCond %{HTTP_USER_AGENT} "Somebot|Otherbot" [NC,OR]
    RewriteCond %{HTTP_USER_AGENT} "Anotherbot" [NC]
    RewriteCond %{REQUEST_URI} !(\/mypages|\/otherpages) [NC]
    RewriteRule ^(.*)$ index.html? [R=301,L]

Last edited by NiteWave; 01-04-2013 at 07:00 PM..
Reply With Quote
  #2  
Old 01-03-2013, 05:21 PM
NiteWave NiteWave is offline
LiteSpeed Staff
 
Join Date: Sep 2009
Posts: 2,293
try adding index.html in RewriteCond:

RewriteCond %{REQUEST_URI} !(\/mypages|\/otherpages) [NC]
=>
RewriteCond %{REQUEST_URI} !(\/mypages|\/otherpages|\/index\.html) [NC]
Reply With Quote
  #3  
Old 01-04-2013, 12:10 PM
Cremas2 Cremas2 is offline
New Member
 
Join Date: Jan 2013
Posts: 3
Thank you. It is solved.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 02:57 AM.



- Archive - Top
© Copyright 2003-2011 LiteSpeed Technologies, Inc. All rights reserved. Privacy Policy.