Apache-style squid logs

Skip the page content navigation if you do not require links to content sections within this page.

Page Content Navigation

Skip the primary navigation if you do not want to read it as the next section.


Primary navigation

Home Clients Non profits Webfactory Support About us Services

Skip the main content if you do not want to read it as the next section.


Many people in the Zope community use the squid caching server as an http accelerator for their Zope sites.

By default, squid logs in a format useful for analysing cache hits, but not in a format useful for analysing web traffic. To get squid logging in the standard combined log format used by apache and understood by analysis packages like webalizer and awstats, you need to do the following. (Note: when squid 3 becomes stable, you will no longer need to patch the code. I understand that squid 3 is informally considered stable when run as an accelerator).

  1. Get the customlog patch and patch the squid code:
      $ patch -p1 < path-to-customlog-2.5.path
  2. Compile and install squid as normal
  3. Add the following lines to your squid.conf (full config details are here):
      logformat combined %>a %ui %un [%tl] "%rm %ru HTTP/%rv" %Hs %<st "%{Referer}>h" "%{User-Agent}>h" %Ss:%Sh
    access_log /var/log/httpd/access_log combined



The following page sections include static unchanging site components such as the page banner, useful links and copyright information. Return to the top of page if you want to start again.


Page Extras

Skip the main banner if you do not want to read it as the next section.


Page Banner


End of page. You can return to the page content navigation from here.