How to Enable GeoIP plugin in AWStats plesk?

AWStats uses the geoip country plugin for country detection from IP address location, and to populate the geographical traffic statistics. When this plugin is not installed in Plesk AWStats, you won't be able to check the geographical traffic statistics. In this article, we'll show you the steps to install the geoip country plugin in Plesk AWStats.

  1. First we will install the Geo::IP::PurePerl perl module. You can download the latest version of this module from following download link.

    http://search.cpan.org/search?query=Geo%3A%3AIP%3A%3APurePerl&mode=all

    You can also install this module from Windows command line using following command.

    ppm install http://trouchelle.com/ppm10/Geo-IP-PurePerl.ppd
  2. Install the Geo::IPfree perl module. The latest version of this module can be found at following download link.

    http://search.cpan.org/search?query=Geo%3A%3AIPFree&mode=all

    You can also install this module from Windows command line using following command.

    ppm install http://trouchelle.com/ppm10/Geo-IPfree.ppd
  3. Download the file GeoIP.dat, unzip and install it in GeoIP directory. For instance, C:\GeoIP. Note that, this file must be updated periodicaly, to get the accurate statistics.

  4. Apply the read permissions to IIS anonymous user (IUSR_<username>) on GeoIP directory.

  5. Edit the file, %plesk_dir%\Additional\AWStats\wwwroot\cgi-bin\awstats.model.conf and enable geoip plugin as follows.

    LoadPlugin="geoip GEOIP_STANDARD /GeoIP/GeoIP.dat"
  6. To recalculate the web statistics for a specific domain, apply following 2 commands. Be sure that you replace "testdomain.tld" with your actual domain name in these commands.

    "%plesk_bin%"\statistics.exe --calculate-one --domain-name testdomain.tld
    "%plesk_bin%"\statistics.exe --generate-domain-webstat --domain-name testdomain.tld


    To calculate the web statistics for all domains, issue the following commands in the same order.

    "%plesk_bin%"\dbclient.exe --direct-sql --sql="select name from domains" > c:\output.txt
    for /F %i in (c:\output.txt); do ("%plesk_bin%"\statistics.exe --calculate-one --domain-name %i);
    for /F %i in (c:\output.txt); do ("%plesk_bin%"\statistics.exe --generate-domain-webstat --domain-name %i);

  • 0 Users Found This Useful

Was this answer helpful?

Related Articles

How do I login to Plesk control panel?

This article will guide you on how to login to Plesk control panel. You can obtain control...