Search Engine: Elastic

Article ID: 3425, created on Nov 30, 2007, last review on Dec 26, 2016


AWStats error: plugin load for plugin 'geoip' failed Error: Plugin load for plugin 'geoip' failed with return code: Error: Can't locate Geo/IP/ in @INC (@INC contains: /usr/lib/perl5/5.8.5/i386-linux-thread-multi /usr/lib/perl5/5.8.5 /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/site_perl /usr/lib/perl5/vendor_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.1 /usr/lib/perl5/vendor_perl/5.8.0 /usr/lib/perl5/vendor_perl . ./lib ./plugins) at (eval 3) line 1. Setup ('./awstats.DOMAIN.conf' file, web server or permissions) may be wrong. Check config file, permissions and AWStats documentation (in 'docs' directory).


Awstats geoip plugin uses perl modules to resolve IP addresses in countries. If you have enabled LoadPlugin="geoip GEOIP_STANDARD" plugin in awstats config file, you should be sure that certain Perl module(s) are installed on the system, because they are not the parts of the the original AWStats package. The error clearly states that there is required Perl module missed: Error: Can't locate Geo/IP/ in ...

So, you have to install Perl module required by this plugin. It may be done in this way^

# perl -MCPAN -e "install Geo::IP::PurePerl"
# perl -MCPAN -e "install Geo::IP"

or, if it doesn`t work for some reason, you can install Perl modules in traditional way by downloading and compiling tarballs:

    1. wget geoip-xxx.tar.gz 
    2. tar -xzf geoip-xxx.tar.gz 
    3. cd geoip-xxx 
    4. perl Makefile.PL 
    5. make && make install 

Here is the link where you can find geoip Perl modules:

You have to install two first packages - Geo::IP and Geo::IP::PurePerl (because Geo::IP::PurePerl depends on Geo::IP) Sometimes it can ask to install GeoIP C API before you can add perl Geo::IP module. You may download this API here:

Once all this back-end is installed on the server, awstats statistics page for domains with enabled GEOIP plugin should work.

Email subscription for changes to this article
Save as PDF