Posted by rp8 on Saturday, December 20, 2008

There is a new version of webalizer. B. Barrett has released two versions this year. There’s no release during 2003-2007, quite a long time.

I have tried to build the latest webalizer 2.20-03 from source, but it kept getting undefined symbol gdImgPng error. The needed libgd2 and libpng are not readily available in Ubuntu distro.

Finally, I gave up building from source and downloaded the binary version. Unzipped it to a folder, modified the sample.conf and run the command “./webalizer -c sample.conf”, which only complained about missing libdb-4.4.so. After installing libdb4.4 using “apt-get”, it finally worked.

In nginx.conf, I have a log format main defined as

log_format  main  '$remote_addr - $remote_user [$time_local] "$request" '
                  '$status $body_bytes_sent "$http_referer" '
                  '"$http_user_agent" "$http_x_forwarded_for"';

Webalizer reads this log format without any problem.