[users@httpd] mod_cache caches the 301 response

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

If a request comes for a directory w/o trailing slash, it gets cached and the subsequent requests see:

Moved Permanently
The document has moved here

for try to access the URL:
http://www.beach-clothing.com/where-to-buy

The configuration has two apache 2.0.53. The one running on port 80 has mod_disk_cache which sends requests to 8080 via ProxyPassReverse.

Here is my Virtual Host Config:

<VirtualHost 66.235.181.69>
ServerAlias beach-clothing.com www.beach-clothing.com
ServerName www.beach-clothing.com
ServerAdmin webmaster@xxxxxxxxxxxxx
DocumentRoot /var/www/public_html/beach-clothing
ServerPath /beach-clothing
RewriteEngine On
RewriteCond %{HTTP_HOST}   !^www\.beach-clothing\.com [NC]
RewriteCond %{HTTP_HOST}   !^$
RewriteRule ^/(.*)         http://www.beach-clothing.com/$1 [L,R=301]
#Enable Caching
CacheDisable /index.html
CacheEnable disk /
RewriteCond %{SERVER_PORT} ^25$
RewriteRule /* - [F]
RewriteRule ^(.*)\/$ $1/index.html [P]
RewriteRule \.(gif|jpg|png|txt|css|js|ico|swf)$ - [last]
RewriteRule ^/(.*)$ http://www.beach-clothing.com:8080/$1 [proxy]
ProxyPassReverse / http://www.beach-clothing.com:8080/
</VirtualHost>

How do I solve this problem? If anyone has any clue / pointer?

Thanks.

Devendra Singh


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
  "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx



[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux