免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 3943 | 回复: 3
打印 上一主题 下一主题

[Web] 请教linux下Awstats多域名配置 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2008-10-17 09:13 |只看该作者 |倒序浏览
我在redhat as4 u6下跑着nginx,Nginx做反向代理,我安装awstats 6.8分析某一个站点没有问题,但多个站点就报错,请教各位平时在linux下分析多个域名,并且分别不同的日志文件时,是如何操作的呢?

我参考了下面的文档资料来配置,但就是报错,说日志格式不对!
http://www.anywolfs.com/liuhui/article.asp?id=288


[root@AS31 Geo-IPfree-0.2]# /usr/local/awstats/tools/awstats_updateall.pl now -a wstatsprog=/usr/local/awstats/wwwroot/cgi-bin/awstats.pl -configdir=/usr/local/awstats/wwwroot/cgi-bin/ -lang=cn -excludeconf=common
Running '"/usr/local/awstats/wwwroot/cgi-bin/awstats.pl" -update -config=bbs -configdir="/usr/local/awstats/wwwroot/cgi-bin/"' to update config bbs
Create/Update database for config "/usr/local/awstats/wwwroot/cgi-bin/awstats.bbs.conf" by AWStats version 6.8 (build 1.910)
From data in log file "/home/log/bbs.access.log"...
Phase 1 : First bypass old records, searching new record...
Searching new records from beginning of log file...
Jumped lines in file: 0
Parsed lines in file: 484
Found 144 dropped records,
Found 340 corrupted records,
Found 0 old records,
Found 0 new qualified records.

Running '"/usr/local/awstats/wwwroot/cgi-bin/awstats.pl" -update -config=register -configdir="/usr/local/awstats/wwwroot/cgi-bin/"' to update config register
Create/Update database for config "/usr/local/awstats/wwwroot/cgi-bin/awstats.register.conf" by AWStats version 6.8 (build 1.910)
From data in log file "/home/log/register.access.log"...
Phase 1 : First bypass old records, searching new record...
Searching new records from beginning of log file...
AWStats did not find any valid log lines that match your LogFormat parameter, in the 50th first non commented lines read of your log.
Your log file /home/log/register.access.log must have a bad format or LogFormat parameter setup does not match this format.
Your AWStats LogFormat parameter is:
2
This means each line in your web server log file need to have "MSIE Extended W3C log format" like this:
date time c-ip c-username cs-method cs-uri-sterm sc-status sc-bytes cs-version cs(User-Agent) cs(Referer)
And this is an example of records AWStats found in your log file (the record number 50 in your log):
222.76.192.247 - - [16/Oct/2008:15:02:06 +0800] "GET /img/bg.gif HTTP/1.1" 304 138 "http://register.chinarenservice.com/actived.php?activeCode=JkBiJVZPeWqeC1js4KR4" "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR 1.1.4322)" "-"
Setup ('/usr/local/awstats/wwwroot/cgi-bin/awstats.register.conf' file, web server or permissions) may be wrong.
Check config file, permissions and AWStats documentation (in 'docs' directory).

Running '"/usr/local/awstats/wwwroot/cgi-bin/awstats.pl" -update -config=chinarenservice -configdir="/usr/local/awstats/wwwroot/cgi-bin/"' to update config chinarenservice
Create/Update database for config "/usr/local/awstats/wwwroot/cgi-bin/awstats.chinarenservice.conf" by AWStats version 6.8 (build 1.910)
From data in log file "/home/log/chinarenservice.access.log"...
Phase 1 : First bypass old records, searching new record...
Direct access after last parsed record (after line 84150)
AWStats did not find any valid log lines that match your LogFormat parameter, in the 50th first non commented lines read of your log.
Your log file /home/log/chinarenservice.access.log must have a bad format or LogFormat parameter setup does not match this format.
Your AWStats LogFormat parameter is:
2
This means each line in your web server log file need to have "MSIE Extended W3C log format" like this:
date time c-ip c-username cs-method cs-uri-sterm sc-status sc-bytes cs-version cs(User-Agent) cs(Referer)
And this is an example of records AWStats found in your log file (the record number 50 in your log):
221.218.169.67 - - [16/Oct/2008:18:04:40 +0800] "GET /images/mainNav_mouseUp.gif HTTP/1.1" 304 137 "http://www.chinarenservice.com/space.html?ch=2" "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1)" "-"
Setup ('/usr/local/awstats/wwwroot/cgi-bin/awstats.chinarenservice.conf' file, web server or permissions) may be wrong.
Check config file, permissions and AWStats documentation (in 'docs' directory).

论坛徽章:
0
2 [报告]
发表于 2008-10-23 11:51 |只看该作者
终于搞定啦,就是把配置文件多复制几份修改一下相关参数就可以了!

论坛徽章:
4
白银圣斗士
日期:2015-11-24 10:40:40技术图书徽章
日期:2015-11-26 13:47:47平安夜徽章
日期:2015-12-26 00:06:30技术图书徽章
日期:2016-07-19 13:54:03
3 [报告]
发表于 2008-10-23 11:56 |只看该作者
呵呵,就是几个域名几个配置文件分析就ok

论坛徽章:
18
巳蛇
日期:2014-12-03 08:27:5115-16赛季CBA联赛之吉林
日期:2016-04-18 15:24:24qiaoba
日期:2016-06-17 17:41:1615-16赛季CBA联赛之八一
日期:2016-06-20 15:13:1415-16赛季CBA联赛之广夏
日期:2016-06-29 10:38:28极客徽章
日期:2016-12-07 14:03:4015-16赛季CBA联赛之吉林
日期:2017-03-06 13:47:55
4 [报告]
发表于 2009-09-29 14:27 |只看该作者
试了好长时间,终于弄好了
多域名,多域名日志,日志按天分割,awstats查看,加密码限制
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP