• Debian 11 is approaching its end-of-life (vendor EOL date - August 31, 2026). Plesk Obsidian 18.0.80 will be the last release to support it.
    If you are running Plesk Obsidian on Debian 11, we recommend you upgrade those servers to Debian 12 using our dist-upgrade tool.
  • We plan to deprecate and remove the support for XML RPC protocol versions earlier than 1.6.9.1 in Plesk Obsidian 18.0.82. We strongly recommend that you update all existing integrations using earlier versions of the XML RPC protocol to comply with the version 1.6.9.1 specification.

Resolved Awstats and GeoIP - Statistic page errors: Can't locate Geo/IP.pm and Geo/IP/PurePerl.pm in @INC

quark

Basic Pleskian
Plesk version: Plesk Onyx v17.5.3_build1705170317.16 os_CentOS 7

Steps:
1. I 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
# 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
# echo 'extension=geoip.so' > /opt/plesk/php/7.1/etc/php.d/geoip.ini

# plesk bin php_handler --reread

2. I added 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

3. I copied latest GeoIP.dat file to /usr/share/GeoIP/GeoIP-initial.dat

4. Installed perl cpan and GeoIP perl modules Geo::IP:: PurePerl, Geo::IP, YAML (like in: Statistics page fails to open with error: Plugin load for plugin 'geoip' failed)

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

5. 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).

How can I fix these errors?
Thank you.
 
Even though, when I posted the above thread, I tried to update the statistics several times and the error was still present, now (after a couple of days) I visited the Web Statistic page again and the error is gone ... So... I think it's a miraculous self-healing :) or my statistic update procedure wasn't correct...
 
Back
Top