• The APS Catalog has been deprecated and removed from all Plesk Obsidian versions.
    Applications already installed from the APS Catalog will continue working. However, Plesk will no longer provide support for APS applications.
  • Please be aware: with the Plesk Obsidian 18.0.78 release, the support for the ngx_pagespeed.so module will be deprecated and removed from the sw-nginx package.

Awstats Error's Enabling GeoIP Plugin

T

TommyT

Guest
Hello!

Any help would be much appreciated for my issue. I've just moved from one dedicated server to a better one. I wanted to see the countries in my awstats, so I followed the following knowledge base post:

http://kb.parallels.com/en/3080

After following these steps, I've check to see that the PurePerl Module is working and updated to the latest. I then changed the following conf files:

/etc/awstats/awstats.conf
/etc/awstats/awstats.model.conf
/usr/local/psa/etc/awstats/awstats.test.net-http.conf
/usr/local/psa/etc/awstats/awstats.test.net-https.conf
/usr/local/psa/etc/awstats/awstats.test.net-ftp.conf
/usr/local/psa/etc/awstats/awstats.test.net-anon_ftp.conf

and enabled the GeoIP plugin in all the above files by updating this line:

LoadPlugin="geoip GEOIP_STANDARD /usr/local/share/GeoIP/GeoIP.dat"


After saving the conf files, this is the following message i get when I enter awstats from my plesk panels:

Error: Plugin load for plugin 'geoip' failed with return code: Error: Can't locate Geo/IP.pm in @INC (@INC contains: /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 . /var/www/cgi-bin/awstats/lib /var/www/cgi-bin/awstats/plugins) at (eval 2) line 1. Can't locate Geo/IP/PurePerl.pm in @INC (@INC contains: /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 . /var/www/cgi-bin/awstats/lib /var/www/cgi-bin/awstats/plugins) at (eval 3) line 1. Error: Need Perl module Geo::IP or Geo::IP::purePerl

Setup ('/usr/local/psa/etc/awstats/awstats.test.net-http.conf' file, web server or permissions) may be wrong.
Check config file, permissions and AWStats documentation (in 'docs' directory).


I tried a few server restarts, and making sure PurePerl is installed by running the command:

perl -MCPAN -e "install Geo::IP::purePerl"

to which the result says its up to date. I've also made sure the GeoIP.dat was there and permissions are correct on it. To my frustration, I commented out the conf files in hopes I can read my stats again without the countries, but I'm still getting the error message above, which don't make any sense to me because the GeoIP Plugin should be disabled.

I hope someone can enlighten me or give me steps to try. It's driving me insance. Thanks in advance!
 
Same errors in Plesk v12.5.30_build1205150826.19 os_CentOS 7 and Plesk Onyx v17.5.3_build1705170317.16 os_CentOS 7:

Installed geoip for all PHP versions:
Code:
yum install geoip-devel
pecl install geoip
echo 'extension=geoip.so' > /etc/php.d/geoip.ini
/opt/plesk/php/5.6/bin/pecl install geoip
echo 'extension=geoip.so' > /opt/plesk/php/5.6/etc/php.d/geoip.ini
/opt/plesk/php/7.0/bin/pecl install geoip-1.1.1 (beta!)
echo 'extension=geoip.so' > /opt/plesk/php/7.0/etc/php.d/geoip.ini
/opt/plesk/php/7.1/bin/pecl install geoip-1.1.1 (beta!)
echo 'extension=geoip.so' > /opt/plesk/php/7.1/etc/php.d/geoip.ini
plesk bin php_handler --reread

Edited LoadPlugin="geoip GEOIP_STANDARD /usr/share/GeoIP/GeoIP.dat" in:
/etc/awstats/awstats.conf
/etc/awstats/awstats.model.conf and
/usr/local/psa/etc/awstats/awstats.domain.tld-http.conf

Copied latest GeoIP.dat to /usr/share/GeoIP/GeoIP-initial.dat

Installed perl cpan and GeoIP perl modules:
Code:
yum install perl-CPAN perl-CPAN-Changes perl-CPAN-Meta perl-CPAN-Meta-Requirements
cpan install CPAN
cpan reload CPAN

perl -MCPAN -e "install Geo::IP::PurePerl"
perl -MCPAN -e "install Geo::IP"
cpan -i YAML

When trying to access Plesk Web Statistics for a domain, the following errors appears:
Code:
Error: Plugin load for plugin 'geoip' failed with return code: Error:
Can't locate Geo/IP.pm in @INC (@INC contains: /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 . /var/www/cgi-bin/awstats/lib /var/www/cgi-bin/awstats/plugins) at (eval 4) line 1.
Can't locate Geo/IP/PurePerl.pm in @INC (@INC contains: /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 . /var/www/cgi-bin/awstats/lib /var/www/cgi-bin/awstats/plugins) at (eval 5) line 1. Error: Need Perl module Geo::IP or Geo::IP::PurePerl

Setup ('/usr/local/psa/etc/awstats/awstats.domain.tld-http.conf' file, web server or permissions) may be wrong.
Check config file, permissions and AWStats documentation (in 'docs' directory).
 
Back
Top