apache - 503 server response for Googlebot -


I put an .htaccess file in my webroot with the following contents

  RewriteBase / RewriteCond% {HTTP_USER_AGENT} ^. * (Googlebot | Googlebot | Mediapartners | Adsbot | Feedfetcher) -? (Google | Image)? [NC] REERRR * / Var / www / 503.html  

This website is in maintenance mode, and I should not index yet. I have tested the code with the Firefox User-Agent Switcher Plugin, and after entering the login log it shows at the end of each log entry, but looking at Tepperda or Firebug, it still returns 200 server feedback instead of 503 . What am i doing wrong Content of " > " Mozilla / 5.0 (compatible; Googlebot / 2.1; + http: //www.google.com/bot.html) "

/var/www/503.html

  & lt ;! DOCTYPE HTML Public "- // W3C // DTD HTML 3.2 / EN" & gt; & Lt; Html & gt; & Lt; Top & gt; & Lt; Title & gt; 503 - Service temporarily unavailable & lt; / Title & gt; & Lt; / Head & gt; & Lt; Body & gt; & Lt; H1 & gt; 503 - Service temporarily unavailable & lt; / H1> & Lt; P & gt; Sorry, this website is currently down for maintenance, please try again later & lt; / P & gt; & Lt; / Body & gt; & Lt; / Html & gt;  

::: Edit ::: The small snippet is added from: rewrite.log, here is a small sample, I went through the whole log, and everything is a javascript or image file Referring to:

  172.16.173.26 - - [15 / Jun / 2010: 15: 03: 31 --0500] [qa-test.com/sid#2b6c1c8ba938] [rid # 2b6c24cfdd18 / Initial] (4) [perdir /var/www/qa-test.com/web/] RevertCand: input = '' pattern = '^. * (Googlebot | Googlebot | Mediapartners | Adsbot | Feedfetcher) -? (Google | Image)? ' [NC] = & gt; You have an infinite loop. The result of your rewriting is being rewritten.  
  rewrite / rewrite %% {HTTP_USER_AGENT} (? Googlebot | Googlebot | Mediapartners | Adsbot | Feedfetcher) -? (?: Google | Image)? [NC] Reverted $ 0! (?: ^ | /) 503 \ .hmml $ reverite. * /var/www/503.html [R = 503]  

@BailsC said, you also need a R flag.


Comments

Popular posts from this blog

windows - Heroku throws SQLITE3 Read only exception -

lex - Building a lexical Analyzer in Java -

python - rename keys in a dictionary -