Webalizer hates Googlebot Mobile

For reasons that are pretty much historical, I use Webalizer for analysing my web site access logs. (I’m in the market for something better: any suggestions would be welcome.) Since earlier this month, however, my statistics have been broken: Webalizer died with a SEGFAULT every time it tried to parse the access log. The culprit wasn’t too difficult to find, but it was an interesting exercise that probably benefits from being passed on.

In order to try to work out what was happening, I employed the services of strace, a handy debugging tool that monitors the system calls made by an application.

strace -o strace.log webalizer (normal command-line options)

After a few minutes of parsing, Webalizer died as before. I checked the last few lines of strace.log.

read(3, ".1" 200 5981 "http://po-ru.com/p"..., 4096) = 4096
read(3, "ul/small/IMG_2233.JPG HTTP/1.1" "..., 4096) = 4096
read(3, "ot-Mobile/2.1; +http://www.googl"..., 4096) = 4096
--- SIGSEGV (Segmentation fault) @ 0 (0) ---
+++ killed by SIGSEGV +++

From this, I could see that the last section parsed contained the text ‘ot-Mobile’. That was sufficiently unusual as a user agent to pique my interest. Running grep on the logs revealed something worth following up: a user agent I’d never seen before.

"Nokia6820/2.0 (4.83) Profile/MIDP-1.0 Configuration/CLDC-1.0 
(compatible; Googlebot-Mobile/2.1; +http://www.google.com/bot.html)"

From there, I did something very simple: I just removed the four lines containing ‘Googlebot-Mobile’ from the access log before feeding it to Webalizer.

It worked.

This warrants further investigation, but for now, I’m happy to have fixed the problem and to have got my logs back.

Comments

Skip to the comment form

  1. Mark Robson

    Wrote at 2006-03-01 10:10 UTC using Firefox 1.5.0.1 on Linux:

    I just had exactly the same problem and reached the same conclusion. I hope I shall be able to patch webalizer to fix the bug later; I’ll put the patch somewhere useful.

    Mark
  2. Stone Steps

    Wrote at 2006-03-13 02:12 UTC using Firefox 1.5.0.1 on Windows XP 64 or Server 2003:

    Stone Steps Webalizer can handle this user agent. See the website for details.
  3. Patrick

    Wrote at 2007-09-29 16:30 UTC using Internet Explorer 7.0 on Windows XP:

    There is a patch on the internet to solve that problem:
    http://groups.google.com/group/fj.sources/browse_thread/thread/06ec89c92eab068b

    The next version of Webalizer Xtended (http://www.patrickfrei.ch/webalizer/) will fix that problem, too.

Leave a comment

Please read the comment guidelines before posting. Comments are Gravatar-enabled. Your email address will not be published.

To prove that you’re human, type human in the Bot check field.

Trying to post some program output or a long code sample? Please use a paste service and link to it instead.