半夜忽然睡醒沒事!忽然想到AWStats的log檔,怎麼看就有某些地方怪怪的…

上了官網才看到原來某些的功能要透過Plug-in來做~不過一開始沒有安裝所以都沒有看到應該出現的資料。

這裡有相關的Plug-in的資訊。

Standard free plugins : tooltips, decodeutfkeys, ipv6, hashfiles, geoip, geoipcity, userinfo, hostinfo, clusterinfo, urlalias, timehires, timezone, rawlog, graphapplet
Other plugins (require other licensed product to work) : geoip_region_maxmind, geoip_isp_maxmind, geoip_org_maxmind,

上面是常用的外掛

要把上面的PLUG-IN開啟才行!

至於GeoIP有一些IP是需要額外的檔案來使用的~在 這裡 有一些相關的資訊

wget -N -q http://geolite.maxmind.com/download/geoip/database/GeoLiteCountry/GeoIP.dat.gz
wget http://www.maxmind.com/download/geoip/database/GeoLiteCity.dat.gz
GeoIP.dat 是其中主要的檔案,可從 MAXMIND 的網站下載,或是透過 Complier的方式把檔案做出來。
然而在dreamhost的虛擬主機裡,已經有放一個了,不過日期有點舊了XD

total 716
-rw-r–r– 1 root root  717466 2007-10-05 11:34 GeoIP.dat

所以就直接從官方網站上抓了 geoip.dat && GeoLiteCity.dat 來使用.

而在配置上

LoadPlugin=”geoip GEOIP_STANDARD /home/~~~/awstats/GeoIP.dat”
LoadPlugin=”geoip_city_maxmind GEOIP_STANDARD /home/~~~/awstats/GeoLiteCity.dat”

要把絕對路徑打上

至於由 MAXMIND 抓下來的檔案 是.gz的 就利用指令gunzip GeoLiteCity.dat.gz 下去解

最後出來的成果.. 其實沒什麼FUㄟXD

來源IP的國別&&城市別

作業系統

Hits: 4