1.从官网下载最新的的awstats,解压缩
# unzip awstats-6.95.zip
# mv awstats-6.95 /usr/local/awstats
2. 安装配置awstats,以我服务器上的网站phpadmin.dean.com为例,根据情况请自行更改网址-----> Check for web server install
Found Web server Apache config file '/etc/httpd/httpd.conf' <=============读取你的httpd配置文件
-----> Check and complete web server config file '/etc/httpd/httpd.conf'
All AWStats directives are already present.
-----> Update model config file '/usr/local/awstats/wwwroot/cgi-bin/awstats.model.conf'
File awstats.model.conf updated.
-----> Need to create a new config file ?
Do you want me to build a new AWStats config/profile
file (required if first install) [y/N] ? y <===============第一次需要创建一个新的config fiel
-----> Define config file name to create
What is the name of your web site or profile analysis ?
Example: www.mysite.com
Example: demo
Your web site, virtual server or profile name:
> phpadmian.dean.com <====================这里输入你要记录的网址,当然是自己httpd服务器上的
-----> Define config file path
In which directory do you plan to store your config file(s) ?
Default: /etc/awstats
Directory path to store config file(s) (Enter for default):
> <================配置文件存放路径,一般默认/etc/awstats即可,直接回车
-----> Create config file '/etc/awstats/awstats.phpadmin.dean.com.conf'
Config file /etc/awstats/awstats.phpadmin.dean.com.conf created.
-----> Add update process inside a scheduler
Sorry, configure.pl does not support automatic add to cron yet.
You can do it manually by adding the following command to your cron:
/usr/local/awstats/wwwroot/cgi-bin/awstats.pl -update -config=phpadmin.dean.com
Or if you have several config files and prefer having only one command:
/usr/local/awstats/tools/awstats_updateall.pl now
Press ENTER to continue... <====================按回车创建。。。
A SIMPLE config file has been created: /etc/awstats/awstats.phpadmin.dean.com.conf
You should have a look inside to check and change manually main parameters.
You can then manually update your statistics for 'phpadmin.dean.com' with command:
> perl awstats.pl -update -config=phpadmin.dean.com
You can also read your statistics for 'phpadmin.dean.com' with URL:
> http://localhost/awstats/awstats.pl?config=phpadmin.dean.com
Press ENTER to finish... <=============创建成功,按回车退出
3.修改配置文件/etc/awstats/awstats.drupal.dean.com.conf ,找到logFile那一行,将其修给为自己网站的访问日志路径,并且增加一样DataDir指向上面创建的data目录
LogFile="/usr/local/apache/logs/druap.dean.com-access_log"
DataDir="DataDir="/usr/local/awstats/data"
4.生成统计日志网页。
1)首先需要创建/var/lib/awstats目录,否则在生成日志网页的时候报错
2)确保你的网站访问日志格式为combined ,否则会报错
This means each line in your web server log file need to have "combined log format" like this:
3)确保awstats.pl有执行权限,否则无法生成日志网页
4)生成日志网页
5. 查看日志网页
在浏览器里输入:http://phpadmin.dean.com/awstats/awstats.pl?config=phpadmin.dean.com
效果如下
6.可以将以上命令放到crontab中执行,并根据需要指定更新的频率和时间:
33 6 * * * /usr/local/awstats/wwwroot/cgi-bin/awstats.pl -update -config=phpadmin.dean.com >/dev/null 2>&1
分享到:
相关推荐
awstats_配置详解
Advanced Web Statistics(AWStats)是一个免费的功能强大的服务器日志分析工具,它可以告诉你所有的Web统计数据,包括访问量、访问者数量、页面、点击、高峰时段、操作系统、浏览器版本、搜索引擎、关键字、机械访问...
awstats在windows+apache环境下的安装与配置,包括很多在wwindows下需要注意的与linux不同的细节,以及最后的调试过程的注意事项
它可以统计您站点的如下信息: 一:访问量,访问次数,页面浏览量,点击数,数据流量等 二:精确到每月、每日、每小时的数据 三:访问者国家 四:访问者IP 五:Robots/Spiders的统计 六:访客持续时间 七:对不同...
本文介绍了Awstats for Linux的简易安装、配置及测试方法。
NULL 博文链接:https://qlqllu.iteye.com/blog/1576099
绍Awstats for Linux的安装与配置测试。
1 安装软件 1. 安装包下载地址:http://awstats.sourceforge.net/ 2. 上传awstats-7.0.tar.gz到/usr/local目录下。 3. 赋予执行权限。 #chmod +x awstats-7.0.tar.gz 4. 解压文件。 #tar zxvf awstats-7.0.tar.gz 5....
Linux下配置Tomcat日志分析 awstats 里面有详细配置说明以及需要修改的tomcat配置文件 和jar包等等
在我的上一篇文章《使用Nginx提升网站访问速度》中介绍了Nginx这个HTTP服务器以及如何通过它来加速网站的访问速度。在实际的网站运营中,我们经常需要了解到网站的访问情况,例如每天有多少IP在访问、PV数是多少、...
最好的TomCat来访用户统计软件,安装简单,功能强大,支持中文。
awstats下载和安装: 此软件为perl脚本,机器上有perl环境就可以直接执行了。
Nginx 日志分析 AWStats + JAWStats 安装配置 Awstats 是一款基于 Perl 的 WEB 日志分析工具,而 JAWStats 是一款基于 PHP 的统计套件,旨在为 Awstats 提供更为精美图形界面。
Tomcat下配置AWSTATS.pdf
此文档包含了linux和windows的配置及所需文件。 Awstats是一个免费非常简洁而且强大有个性的统计工具。它可以统计您站点的如下信息: 一:访问量,访问次数,页面浏览量,点击数,数据流量等 二:精确到每月、...
awstats配置详解[参考].pdf
利用awstats对日志进行分析 以网页的方式查看自己网站的流量 PV 等
AWStats配置与应用详细讲解.doc
Awstats 7分析squid日志【安装+配置】
AWSTATS的简单安装及配置[参考].pdf