Httplog is a program that helps with logging for Apache by supporting filename formatting with strftime(3) and log rollover.
Httplog takes one argument at the command line, the path to a logfile as a template. The template pathname can use any valid special characters permitted in strftime(3). Optional arguments can be appended to the command line to specify additional settings. For example, you can use the `-u ' and `-g ' options to have httplog run as a different user and/or group, which prevents potential security risks. Alternatively, you can specify `-b ' to have httplog use a custom buffer size for memory storage of log data, rather than the default value of just line buffering mode (flushes data per newline).
With the `-z' option, you can also specify that httplog gzip all logfiles once it's done writing all data to them (when a rollover period hits and a new logfile is to be created). You may even have a symlink to the currently active logfile by using the `-s' option and specifying a filename to be used as the symlink.
One of the most significant benefits of using httplog is its ability to make Apache act similarly to Microsoft's IIS webserver in its logging style. This makes it easy to maintain logfiles for statistics packages in an easily organizable manner without requiring user intervention. Since v1.5, the buffer option was added to help extremely large sites that get thousands of hits per second, and typically disable logging to save their hard drives from dying. The buffer size option can be used to create an extremely large buffer in ram so that logfiles would not be flushed as often as if it were in line buffering mode, and in essence, could prolong the life of your valuable drives by decreasing their activity.
What's new in this release is that a couple of lines of code were removed that could cause segfaults if errors were imminent while opening a new file or allocating the buffer memory. Overall, this software is a great tool for managing your Apache logs with ease, and we highly recommend it.
Version 2.1: N/A