Citation :
Install and Setup
1) With Apache Server (on Unix/Linux, Windows, MacOS...)
* Configure your apache web server to have NCSA combined/XLF/ELF log format (you can use your own log format but this predefined logformat is often the best choice and made setup easier). You can do this by changing, in httpd.conf, following directives (See your apache manual for more information):
CustomLog /yourlogpath/yourlogfile common
into
CustomLog /yourlogpath/yourlogfile combined
To be sure the log format change is effective, you can stop Apache, remove all old log files, restart Apache and go to your homepage. This is an example of records you should get then in the new log file:
62.161.78.75 - - [dd/mmm/yyyy:hh:mm:ss +0000] "GET / HTTP/1.1" 200 1234 "http://www.from.com/from.html" "Mozilla/4.0 (compatible; MSIE 5.01; Windows NT 5.0)"
* Copy the contents of the uncompressed cgi-bin folder from your hard drive to your server's cgi-bin directory (this includes awstats.pl, awstats.model.conf, and the lang, lib and plugins sub-directories). * If necessary (should not with most Perl interpreter), edit the first (top-most) line of awstats.pl file that is
#!/usr/bin/perl
to reflect the path were your perl interpreter is installed. Default value works for most of Unix OS, but it also might be
#!/usr/local/bin/perl
With Apache for Windows and ActivePerl interpreter, it might be
#!c:/program files/activeperl/bin/perl
* Move AWStats icon sub-directories and its content into a directory readable by your web server, for example /yourwwwroot/icon or /yourwwwroot/icons.
* Copy awstats.model.conf file into a new file named awstats.virtualhostname.conf (or awstats.conf). Note: When you will run AWStats, it will first look for a config file named awstats.virtualhostname.conf, and, if not found, will look for awstats.conf.
Whatever the name you choose, this new file must be stored in
- /etc/opt/awstats or /etc/awstats or /etc or same directory than awstats.pl (so cgi-bin) for Unix/Linux users.
- same directory than awstats.pl (so cgi-bin) for Windows and other OS.
Edit this new config file with your own setup :
- Change LogFile value with full path of your web server log file (You can also use a relative path from your awstats.pl directory).
- Check if LogFormat has the value "1" (it means "NCSA apache combined/ELF/XLF log format" ).
- Change DirIcons parameter to reflect relative URL of icon directory.
- Edit SiteDomain parameter with the main domain name or the intranet web server name used to reach the web site to analyze.
- You can change other parameters if you want.
Install and Setup is finished. You can jump to the Build/Update Statistics section.
|