Personal tools
You are here: Home Documentation Tutorials Optimizing Plone Performance Caching setup using Apache 2.0
Support

Get Help

Join our chat rooms or support forums if you have more specific questions.

Plone Training
Learn how to design, build, and deploy a website in Plone through one of the numerous Plone training sessions around the world.
Find Plone training…
 
Document Actions

Caching setup using Apache 2.0

How to set up the caching using Apache 2.0.

Alexander Limi

This tutorial will show you a simple and effective way to use caching to make your Plone site a production-worthy setup capable of delivering in excess of 100 pages per second given proper hardware. (In progress)
Page 4 of 5.

The major differences from Limi's instructions on Apache 1.3 were:

  • In order to get apache proxying the requests the following line needs to be uncommented in the httpd.conf:
      LoadModule proxy_http_module modules/mod_proxy_http.so
    
  • The following modules are also needed to get the caching working. They may not appear in your httpd.conf so if not, you'll have to add them:
      LoadModule disk_cache_module modules/mod_disk_cache.so
      LoadModule cache_module modules/mod_cache.so
    
  • The following setting in httpd.conf file was not enough:
      CacheRoot "/var/cache/artpropensity.com"
    

It must be proceeded by: CacheEnable disk /

so that it looks like:

  CacheEnable disk /
  CacheRoot "/var/cache/artpropensity.com"

  • I also had to set explicit IP's and hosts in my /etc/hosts file, as in:
      192.168.10.10 www.artpropensity.com artpropensity.com 
    

This is so that the following settings in the httpd.conf file will get resolved properly:

  ProxyPass / http://www.artpropensity.com:9080/VirtualHostBase/http/www.artpropensity.com:80/artpropensity/VirtualHostRoot/
  ProxyPassReverse / http://www.artpropensity.com:9080/VirtualHostBase/http/www.artpropensity.com:80/artpropensity/VirtualHostRoot/

  • Using "wget -sS ..." as command line also did not work for me. I ended up running a browser on an external server using X-windows. I set the browser to no-cache (check for new page each time) to make sure that it did not cache items and instead made a full request to Apache each time it accessed the site. I also used your advice and performed:
      $ tail -f Z2.log
    

to make sure that Plone was not serving up .js, .css, .gif, etc. and instead Apache was serving them up once cached. I did notice 304's on some items, but I assume that's because the browser was set to no-cache and it forced Apache to check with Plone to see if the file had changed.

I noticed a speed increase from 4 requests/sec to an average of 300 using Apache 2 caching

 
by Alexander Limi last modified February 8, 2006 - 10:00
Contributors: Alexander Limi, Seb Potter
All content is copyright Plone Foundation and the individual contributors.

For any issues with the web site functionality, please file a ticket.

Please consult the policy on plone.org content if you want your content published on this site.

Servers and hosting by