Daily Archives: Friday, 18th April 2008
Statistical Slip-up
A long time ago, I set up AWStats, a very comprehensive website stats application, so I could see how many people were visiting Losing it[1], where they came from[1], and much more. After a while, I was distracted by the nifty WordPress.com Stats plugin, which tells me nice things about which posts have the most views, and so on, but doesn’t do all the pretty colours and other stuff that AWStats does. Then came the move to a Dreamhost virtual private server, which had the unfortunate side effect of breaking my automagic regular processes – one to back up the database and email it to me every day[2], and one to update AWStats once a day.
Eventually, I noticed the lack of regular database emails, and got Dreamhost to deliver the necessary kick to the server, but I somehow managed to mangle my AWStats set-up.
Once I got it running again, I noticed that the number of daily visits seemed to have dropped enormously. It had gone from anywhere between 150 and 350 (or more) a day to around 50 a day. Now that just didn’t seem right. The other stats thingy suggested I was getting a lot more visitors than that, so something had to be wrong. Were the logs not getting updated? Were internet gnomes eating my visitors? Well, no. It was all much simpler than that.[3]
This is what happens: Every day at midnight (server time, 8am UK time[4]), the webserver starts a new log file. It saves the previous day’s log with a name like access.log.2008-04-17, which is nice and easy for AWStats to find and read. What should happen is that a few hours later (I have it set for 3am server time), AWStats grabs the previous day’s file and does its analysis thingies. Now this is a pretty standard configuration, and it generally works very well.
But somehow, I’d scrambled the settings file. Instead of looking at the previous day’s log, it was looking at the current day’s log, so it was only seeing the visitors who dropped in during those three hours.
This also accounts for more visitors showing up in the report if I ran the script manually. I think I’ve fixed it now, but we’ll have to see what it looks like tomorrow to be sure.
This has been a public service announcement for your amusement. No log files were injured in the making of this post.
[1] In terms of geography and clicks
[2] I’m paranoid about my data
[3] Depending what you call “simple”, I guess
[4] Or 7am in that period between “Daylight Saving Time” beginning and British Summer Time beginning
Related posts
Mozy – Medium Term Update
It’s been a couple of months since I last mentioned Mozy, so it’s a good time for an update. You might recall that back in February, it was chugging slowly along with the important job of backing up my RAW photograph files. Well, it chugged for quite some time, but after a while, the speed began to increase. I don’t know if that’s because they’ve upgraded things at their end, or if something has been reconfigured somewhere between me and them, but whatever it was, it did make the later stages of the backup take much less time than the earlier ones.
Uploading 55GB or so of images did take well over a month, but I wasn’t really concerned with how long it took, so long as it actually did it. Once that was done, I added my music library to the job. Most of it consists of copies of my own CDs, but as ripping them all took a loooong time, I’d rather not do it again. And of course, there are tracks bought from iTunes, which I really don’t want to lose. That was another 20GB or so, and took a few weeks.
Once the big stuff was done, I added in other files and general stuff, which didn’t take long at all. And now it’s all done, Mozy is quite happy doing incremental backups when I’m not looking, which means that the previous problem with it eating memory has now gone away completely. Overall, it’s working well for me, and it’s a lot more convenient than swapping discs between various locations, or remembering to burn stacks of CDs or DVDs. I like it.
Related posts
Weight Report – 18 April 2008
There was a slight increase in my weight today, mutter.
I didn’t walk either to or from work today, due to a lack of motivation, or some such, so out of ten possible walks this week, I managed four, which is not very good, tut tut.
I did, however, resist temptation at lunchtime, and had a cheese and pickle sarnie and precisely zero sausage rolls.



