Product:
Search Type:

[How To] Configuring AwStats to show which countries the visitors are coming from?

Article ID: 3080 
Last Review: Feb,10 2008
APPLIES TO:
  • Plesk 8.x for Linux/Unix

RESOLUTION

By default AwStats does not show countries visitors are coming from. To enable this feature,  GeoIP plugin should be configured. Here is the information about this plugin from /etc/awstats/awstats.conf:

# Plugin: GeoIP
# Perl modules required: Geo::IP or Geo::IP::PurePerl (from Maxmind)
# Country chart is built from an Internet IP-Country database.
# This plugin is useless for intranet only log files.
# Note: You must choose between using this plugin (need Perl Geo::IP module
# from Maxmind, database more up to date) or the GeoIPfree plugin (need
# Perl Geo::IPfree module, database less up to date).
# This plugin reduces AWStats speed of 8% !


Usually, geoip.pm plugin coming with AwStats package.
But the Perl modules necessary for plugin work (Geo::IP or Geo::IP::PurePerl) should be installed.
You can get all necessary installation instructions and downloadable plugin files (for example, "Geo::IP::PurePerl Module" library) from here:

http://awstats.sourceforge.net/docs/awstats_contrib.html#geoip
http://www.maxmind.com/app/perl?rId=awstats

The plugin should be enabled in the main AwStats configuration files:

/etc/awstats/awstats.conf
/etc/awstats/awstats.model.conf

And the files that were already configured by Plesk for every domain which can be found in /usr/local/psa/etc/awstats/*.

The line that should be added into all these files looks like:

LoadPlugin="geoip GEOIP_STANDARD /pathto/GeoIP.dat"

Latest GeoIP.dat can be found at http://www.maxmind.com/download/geoip/database/GeoIP.dat.gz.

Note, it might take a couple of days for your stats to start accumulate the countries information.



Please provide feedback on this article

Did this article help you solve your issue?
Yes
No
Partially
I do not know yet
 
Strongly Agree   Strongly Disagree
  9 8 7 6 5 4 3 2 1
The article is easy to understand
The article is accurate
Additional Comments:
*Please provide us with your email address in case we need to contact you.
*Please type the code you can see.
* - required fields