Posted in WWW

Apache + Webalizer

Apache + Webalizer Posted on 2006 年 11 月 11 日Leave a comment

[1.] apt-get install webalizer zlib libpng gd
[2.] 編輯 config,如果有多個 virtual host的 http log 要區分設定檔及內容設定,必存取到同個資料庫

      cp webalizer.conf


# Apache 登錄檔完整路徑與檔名
LogFile   /var/log/httpd/

# 選擇 log file 的格式
LogType   clf

# 當資料處理完畢之後,輸出的目錄
OutputDir  /var/www/usage/

# 當你的 logrotate 不是一個月一次時,必需設定
Incremental     yes    

# 輸出檔案的時候,顯示在最上方的主機名稱  

# 因為執行一個webalizer,如果想再執行第二個webalizer程式時,會因lock而無法執行,所以需分開檔案設定
HistoryName           /var/lib/webalizer/
IncrementalName    /var/lib/webalizer/
DNSCache              /var/lib/webalizer/

# 啟動 DNS lookup查詢,10個子程序來處理
DNSChildren     10

# webalizer時不輸出訊息
Quiet           yes

[3.] 執行
      webalizer -c /etc/
[4.] 排程


      vi /etc/crontab

50 3 * * * root /usr/bin/webalizer -c /etc/ > /dev/null 2>&1

[Q1:] Error: Skipping oversized log record
[A1:] 引用:

Just a typical (normal)webalizer error message, if it finds in the
access_log entries which are caused by attackers who use overlong
pattern access to try out vulnerabilities. Often those are just methods
to attack vulnerable IIS hosts and not Apache(2). See the access_log.1
for that entries.


I don't think it is anything to worry about. I think it is spyware or
hackers trying to find an old exploit in a MS IIS web server. Since you
are running Apache, you have nothing to worry about in regards to the
exploit. But, you get these errors when trying to analyze the log file.



發佈留言必須填寫的電子郵件地址不會公開。 必填欄位標示為 *