Datareign

The Internals of AWStats

Some of the important components of the main script may be found in the page AWStats General Operation and important variables are described in the page awstats.pl Variables

Installation Paths

On Windows systems, AWStats is generally installed inside the Apache2.2 folder. The path to Apache is defined by the environment variable %AWSTATSROOT% (e.g. “E:\Apache2.2”) The components are installed inside the Apache hierarchy as follows…

 %AWSTATSROOT%
   |
    ---AWStats
   |    |
   |     --- DosBatchScripts      'Glue' scripts to run the process
   |    |
   |     --- ServerLogs           Data to be displayed
   |    |
   |     --- SQL                  Queries to build the reports
   |    |
   |     --- wwwroot
   |          |
   |           --- cgi-bin        AWStats configuration files for reports
   |
    --- htdocs                    Login pages and generated report pages

A Note on %AWSTATSROOT%

You cannot reference a Windows/DOS variable in the configuration files, as AWStats does not translate them. Pending further changes to AWStats, configuration file entries will have to be literals, as in DirData=“C:/Apache2.2/AWStats/ServerLogs/Nos”.

General Processing

The web server logs are extracted into work files and these work files are extended according to the rules set within the scripts…

 |  --------    Logging     -----------    AWStats     --------
 | | Server | -----------> | ServerLog |------------> | htdocs |
 |  --------                -----------  ^   |         --------
 |                                       |   |
 |                                       |   |     -------------
 |                                       |    --> | Rollup file |
 |                                       |         -------------
 |                                       |                |
 |                                       | Subsequent run |
 |                                        ----------------

Displaying the Reports

AWStats generates a number of report pages under %AWSTATSROOT%\htdocs\{customer}\{instance}.

Resources

These pages may prove helpfull when maintaining or extending this system…

Last modified: 2009/01/04 09:08