0

I've installed Apache's mod_mem_cache on a server that serves multiple websites. I needed to install it in a hurry as I had a massive traffic spike and was firefighting. It has improved performance massively and all of my sites seem to be serving the correct content, all is well, but I have two questions:

  1. How do I restrict the content types that are cached? Ideally I'd like to cache just css|js|jpg. I tried a <FilesMatch> within the mod_mem_cache.conf but that didn't work.

  2. Is there any way to see which files are in the cache at any point?

Steve Claridge
  • 123
  • 1
  • 6

2 Answers2

1

The answer above is pretty good but...

Personally I would skip mod_mem_cache and install Varnish IMO a much better tool for the job and comes with some very useful debugging and metrics. Put varnish on port 80 and apache on 8080 or another used high level port.

https://www.varnish-cache.org

user132882
  • 11
  • 1
0
  1. http://www.askapache.com/htaccess/apache-speed-cache-control.html
  2. Default path is /var/cache/apache/ (http://httpd.apache.org/docs/2.2/caching.html)
quanta
  • 51,413
  • 19
  • 159
  • 217
dave
  • 303
  • 3
  • 16
  • Hi japao, thanks for the comment but that wasn't exactly what I was looking for. /var/cache is the mod_disk_cache location and the askapache article seems to be talking about cache headers that are sent to the browser. – Steve Claridge Aug 21 '12 at 09:21