Fast & Security Conscious
High-Availability Unix Hosting
Site statistics with Webalizer

Your website activity is recorded, by default, in "raw" log file format. To display this information in a useful way, you need to use a log analysis tool. The Webalizer utility is standard on our servers and is very simple to use.

Making sure your logs are enabled

If you have not used access logs before, you might need to enable them. From the web interface, this is done from the Server Settings section. From the shell interface, you would use the command:

  $ conf set logs yes
Configuring webalizer

Copy the file /etc/webalizer.conf (or, if you are on a FreeBSD server /usr/local/etc/webalizer.conf-dist) somewhere into your home directory:

  $ cp /etc/webalizer.conf $HOME/webalizer.conf

Open up webalizer.conf in your favorite text editor, and edit at least the following entries:

  # The path to your access log file.
  LogFile /home/myself/www/logs/access
  
  # Where to place the generated documents.
  OutputDir /home/myself/www/stats
  
  # Name to use in the title
  HostName www.mydomain.ext
Creating the OutputDir

Create the directory where the generated documents will go:

  $ mkdir $HOME/www/stats

You will probably want to protect this area using passwords or some other authentication method. See the htaccess guide for details on how this is done.

Updating the statistics automatically

Now add an entry to your crontab to periodically update the statistics:

  $ crontab -e

If you are not familiar with the crontab utility, the previous command will start up your favorite text editor (as dictated by $EDITOR). Simply insert the line:

  1 0 * * * webalizer -c $HOME/webalizer.conf

To manually update the statistics right away, run the command from your shell:

  $ webalizer -c ~/webalizer.conf
Links

  End Software Patents!