【问题标题】:AWStats logfile format issueAStats 日志文件格式问题
【发布时间】:2015-06-08 12:47:21
【问题描述】:

我目前正在尝试修复我的日志文件以正确显示 AStats。在我尝试让带宽出现之前,我已经完成了这项工作。我更改了 IIS 日志文件以包含 sc-bytes cs-bytes,然后进入我的配置文件并将其添加到 logformat 并为它们添加。这是格式的样子。

#Fields: date time s-ip cs-method cs-uri-stem cs-uri-query s-port cs-username c-ip cs(User-Agent) sc-status sc-substatus sc-win32-status sc-bytes cs-bytes time-taken

#LogFormat="%time2 %other %method %url         %query      %other %logname    %host %ua           %code     %other       %other          %bytesd    %other   %other"

LogFormat="%time2 %other %method %url %query %other %logname %host %ua %code %other %other %bytesd %other %other"

这是真实日志的样子

2015-06-07 00:03:07 192.168.128.125 POST /ISAPI/DLSapiWP.dll/Rest/heartbeats/ISWEEP153-1/iSweep - 80 - 173.162.54.105 Mozilla/5.0+(Windows;+U;+Windows+NT+5.1;+en-US;+rv:1.9.0.10)+Gecko/2009042316+Firefox/3.0.10 200 0 0 960 1227 733

在我更改日志格式后,AWStats 似乎根本没有更新。我想念或忘记做什么?任何朝着正确方向的点都会有所帮助。

我尝试过的事情:

  1. 正在删除当月的 AStats 数据历史记录。
  2. 手动运行脚本

【问题讨论】:

    标签: logging config awstats


    【解决方案1】:

    原来旧日志文件和新日志文件不兼容。为了使其正常工作,我需要删除所有旧日志并在新日志上运行 AWStats。但是,我能够保留旧月份的历史记录,所以我没有丢失数据。

    流程:

    1. 在第一组日志上运行 AStats
    2. 删除旧日志,保留月份历史记录
    3. 使用字节添加新日志
    4. 对这些运行 AStats。

    旧的带宽不显示,但对于新的带宽,它们工作得很好。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2016-02-14
      • 1970-01-01
      • 2020-11-27
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2011-08-09
      相关资源
      最近更新 更多