Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have frontend apache2 and backend tomcat6 with apache lenya.

Proxy works fine but I want to cache images.

Here is my simple config:

ProxyPass / http://192.168.0.82:8888/
ProxyPassReverse / http://192.168.0.82:8888/


RewriteRule ^/$ index.html [R]
RewriteRule ^/default/live/(.*)$ $1 [R,L]
RewriteRule ^/(.*) http://192.168.0.82:8888/default/live/$1 [P]

ProxyRequests Off
RewriteEngine On

and I tried to cache it in this way:

<IfModule mod_disk_cache.c>
CacheEnable disk /
CacheRoot "/var/cache/mod_proxy"
CacheRoot /home/apache2/cache
CacheDefaultExpire      60
CacheMaxExpire          3600
</IfModule>

But I got nothing...

I even tried this way:

<IfModule mod_mem_cache.c>
CacheEnable mem /
MCacheMaxObjectSize 1024000
MCacheSize 102400
</IfModule>

again without results.

mod_mem_cache and mod_disk_cache enabled. So I don`t know where the problem is... Could you help me, please?

share|improve this question
add comment

1 Answer

up vote 0 down vote accepted

For starters: you have a double entry for the CacheRoot.
Check out this page Some Tuning Tips For Apache Mod_Cache (mod_disk_cache) for some deeper information.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.