I. AWSTAT statistical INFORMATION
Awstat is a very concise and powerful statistical tool. It can count the following information about your site:
1 visits, visits, page views, clicks, data traffic, etc. accurate to monthly, daily, hourly
2 Visitor country, access IP, operating system, browser, etc.
3 Robots/spriders Statistical information
4 Visitor Duration
5 for different file type statistics
6 Page-url Statistics
7 Other information (keywords)
Second, Awstat installation
1, install Perl.
Awstat is a Perl-based Web log analysis tool. Because it's a Perl-based tool, you'll need to install the Perl environment, either under Windows or Linux
[[Email protected] awstats]# tar xvfz perl-5.16.1.tar.gz # Unzip
[Email protected] awstats]# CD perl-5.16.1 #进入目录
[[email protected] perl-5.16.1# rm-f config.sh policy.sh # is a profile that was previously installed and needs to be removed when a new installation or upgrade is installed.
[[Email protected] perl-5.16.1]# sh configure-de #安装时使用默认配置, generally will be OK
[[email protected] perl-5.16.1] #make #编译
[[email protected] perl-5.16.1]# make test
[[email protected] perl-5.16.1]# make install #安装
2, Installation Awstat
Decompression Awstats
[Email protected] awstats]# tar xvfz awstats-6.4.tgz
[Email protected] awstats]# mkdir/etc/awstats
[Email protected] awstats]# mkdir/var/lib/awstats
The two directories created above will be used in a later configuration, a configuration file for site log analysis, and one for storing log data information.
[Email protected] awstats]# cp-r./awstats-7.0/usr/local/
-R indicates that all items in the directory and directory are copied to the/usr/local/directory
[[Email protected] test]# mv awstats-7.0 awstats A rename for ease of operation.
Configure Awstats
[Email protected] tools]# pwd
/usr/local/awstats//tools
Awstats configuration has its own configuration tool awstats_configure.pl, first use VI to open the configure.pl file, see the first line about the Perl Runtime environment configuration is correct.
[Email protected] tools]# VI awstats_configure.pl
#!/usr/bin/perl
.............
[Roo[email protected] tools]# pwd
/usr/local/awstats/tools
[[Email protected] tools]# perl awstats_configure.pl run config file
The awstats_configure.pl tool automatically modifies your Apache configuration and automatically modifies the following information in the Apache configuration file httpd.conf file
[Email protected] conf]# pwd
/usr/local/apache/conf
[Email protected] conf]# VI httpd.conf
awstats_configure.pl automatically adds the following at the bottom of the httpd.conf file:
Awstats_configure.pl will also automatically produce/etc/awstats/awstats.index.conf files based on the information of your answer (the site name to be analyzed) during the installation process.
[Email protected] awstats]# pwd
/etc/awstats
[[email protected] awstats]# ls
Awstats.index.conf
[[Email protected] awstats]# VI awstats.index.conf Configure the following file
This completes the installation and configuration work of the Awstats.
Analysis Log
[Email protected] cgi-bin]# pwd
/usr/local/awstats/wwwroot/cgi-bin
[[email protected] cgi-bin]# chmod +x awstats.pl Add executable permission
[Email protected] cgi-bin]# Perl/awstats.pl-update-config=demo
In the browser, type:
Http://localhost/awstats/awstats.pl?config=demo
You can then see the generated log report.
There may be errors with the following to the prompt, whether you have not encountered, anyway I was met! :
The above error has not found the reason, so, found another way to access the log file.
[Email protected] cgi-bin]# pwd
/usr/local/awstats/wwwroot/cgi-bin
[Email protected] cgi-bin]# Perl awstats.pl-update-config=demo-output-staticlinks >/var/www/html/awastats.html
So we save the log file to the Apache server, named Awastats.html.
In the browser, type:
Http://localhost/awstats.html
can access log files as well!
Awstat (under Linux)