The /etc/webalizer.conf is the default configuration file for Webalizer. With it, you can specify which directories or pages in your web site to analyze, which URLs to hide, and so on. By default,
the Webalizer program will install a sample configuration file named webalizer.conf.sample under the /etc/ directory of Linux. You can use this file to configure your choices and
then rename it webalizer.conf, and the Webalizer program will be able to find and use it. A lot of options exist and it's important to read the documentation that comes with Webalizer for more information on all of
the different setting and parameters. Also, it's important to note that we comment in this Webalizer configuration file only the most common and used parameters.
Edit the webalizer.conf.sample file, vi /etc/webalizer.conf.sample or create the webalizer.conf file, touch /etc/webalizer.conf
and add/change in this file:
LogFile /var/log/httpd/access_log
OutputDir /home/httpd/usage
Incremental yes
PageType htm*
PageType cgi
PageType php
HideURL *.gif
HideURL *.GIF
HideURL *.jpg
HideURL *.JPG
HideURL *.ra
IgnoreURL /taskbar*
This tells the webalizer.conf file to set itself up for this particular configuration setup with:
LogFile/var/log/httpd/access_logThe option
LogFilespecifies the logfile to use with Webalizer. The default log file is supposed to be theaccess_logof Apache Web Server, but you can specifies a different one, like the one Squid Proxy Server makes namedaccess.logif you use it in httpd-accelerator mode. See, Software -Server/Proxy Network, for more information.OutputDir/home/httpd/usageThe option
OutputDirspecifies the location of the output directory to use for the reports of Webalizer. All present and future report files generated by the Webalizer program will be hosted in this directory. It is recommended that you create this directory where your Apache web site resides.Incremental yesThe option
Incrementalif set toYestells the program only to process partial logs file, and allows you to rotate your log files as much as you want without the loss of access information. It's recommended to set this option toYes.PageType htm* cgi phpThe option
PageTypespecifies what file extensions you want Webalizer to consider as a page to count. Each added file extensions must be specified on its own line as shown in the Webalizer configuration file above.HideURL *.gif *.GIF *.jpg *.JPG *.raThe option
HideURLspecifies what kind of items such as graphic files, audio files or othernon-htmlfiles to hide from the reports page. Each added item must be specified on its own line as shown in the Webalizer configuration file above.IgnoreURL /taskbar*The option
IgnoreURLspecifies URLs to be completely ignored from the generated statistics reports. This option can be used to ignore directories that are not important in our statistics reports. It's also useful when you want to manage and class which URLs should be monitored and which should be ignored.
If you decide to use the existent /etc/webalizer.conf.sample file to configure your parameters for Webalizer, don't forget to rename it webalizer.conf or the program will be unable to
use it.
