The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

PECL Fails for geoip install

Discussion in 'General Discussion' started by vicos, Aug 22, 2015.

  1. vicos

    vicos Well-Known Member

    Joined:
    Apr 18, 2003
    Messages:
    62
    Likes Received:
    0
    Trophy Points:
    6
    Trying to install geoip using PECL in WHM fails as follows.

    CentOS 6.6 WHM 11.50.0 (Bulid 29)
    Code:
    Installing PHP Pecl "geoip"
    downloading geoip-1.0.8.tgz ...
    Starting to download geoip-1.0.8.tgz (10,061 bytes)
    .....done: 10,061 bytes
    5 source files, building
    running: phpize
    Configuring for:
    PHP Api Version: 20100412
    Zend Module Api No: 20100525
    Zend Extension Api No: 220100525
    building in /root/tmp/pear/pear-build-root0PJ0kW/geoip-1.0.8
    running: /root/tmp/pear/geoip/configure
    checking for grep that handles long lines and -e... /bin/grep
    checking for egrep... /bin/grep -E
    checking for a sed that does not truncate output... /bin/sed
    checking for cc... cc
    checking for C compiler default output file name... a.out
    checking whether the C compiler works... yes
    checking whether we are cross compiling... no
    checking for suffix of executables...
    checking for suffix of object files... o
    checking whether we are using the GNU C compiler... yes
    checking whether cc accepts -g... yes
    checking for cc option to accept ISO C89... none needed
    checking how to run the C preprocessor... cc -E
    checking for icc... no
    checking for suncc... no
    checking whether cc understands -c and -o together... yes
    checking for system library directory... lib
    checking if compiler supports -R... no
    checking if compiler supports -Wl,-rpath,... yes
    checking build system type... x86_64-unknown-linux-gnu
    checking host system type... x86_64-unknown-linux-gnu
    checking target system type... x86_64-unknown-linux-gnu
    checking for PHP prefix... /usr/local
    checking for PHP includes... -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib
    checking for PHP extension directory... /usr/local/lib/php/extensions/no-debug-non-zts-20100525
    checking for PHP installed headers prefix... /usr/local/include/php
    checking if debug is enabled... no
    checking if zts is enabled... no
    checking for re2c... no
    configure: WARNING: You will need re2c 0.13.4 or later if you want to regenerate PHP parsers.
    checking for gawk... gawk
    checking for geoip support... yes, shared
    checking for geoip files in default path... not found
    configure: error: Please reinstall the geoip distribution
    ERROR: `/root/tmp/pear/geoip/configure' failed
    The geoip.so object is not in /usr/local/lib/php/extensions/no-debug-non-zts-20100525
    Tidying /usr/local/lib/php.ini...
    No changes
    Tidying /usr/local/cpanel/3rdparty/php/54/etc/php.ini...
    No changes
    
    
     
    #1 vicos, Aug 22, 2015
    Last edited by a moderator: Aug 22, 2015
  2. 24x7server

    24x7server Well-Known Member

    Joined:
    Apr 17, 2013
    Messages:
    1,146
    Likes Received:
    34
    Trophy Points:
    48
    Location:
    India
    cPanel Access Level:
    Root Administrator
  3. vicos

    vicos Well-Known Member

    Joined:
    Apr 18, 2003
    Messages:
    62
    Likes Received:
    0
    Trophy Points:
    6
    My understanding was that PECL geoip was an alternative to using mod_geoip. Also, I do not see any mention of this on the PECL geoip page at https://pecl.php.net/package/geoip
     
  4. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,854
    Likes Received:
    676
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello :)

    You will need to install the geoip package through YUM before installing the PECL module. EX:

    Code:
    yum install geoip
    yum install geoip-devel
    Thank you.
     
  5. vicos

    vicos Well-Known Member

    Joined:
    Apr 18, 2003
    Messages:
    62
    Likes Received:
    0
    Trophy Points:
    6
    Thanks Michael,

    I tested this on my local copy of CentOS 6.5

    It does fix the problem and allows "PECL install geoip" to function properly

    However, I did have to load the Extra Packages for Enterprise Linux (EPEL) first:

    yum install epel-release

    Have not tried on the CPANEL server, so not sure if last step is required there.

    Finally, will using the PECL tool in WHM add "extension=geoip.so" to php.ini or does that have to be done manually?

    Will the following work better rather than editing php.ini?

    echo "extension=geoip.so" > /etc/php.d/geoip.ini
     
  6. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,854
    Likes Received:
    676
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    The extension is automatically added when installing the PECL module.

    Thank you.
     
  7. vicos

    vicos Well-Known Member

    Joined:
    Apr 18, 2003
    Messages:
    62
    Likes Received:
    0
    Trophy Points:
    6
    Just a quick update. Performed the following:

    yum install epel-release
    yum install geoip


    WHM-->PHP PECL-->Install geoip

    and it still fails.

    Code:
    downloading geoip-1.0.8.tgz ...
    Starting to download geoip-1.0.8.tgz (10,061 bytes)
    .....done: 10,061 bytes
    5 source files, building
    running: phpize
    Configuring for:
    PHP Api Version:         20100412
    Zend Module Api No:      20100525
    Zend Extension Api No:   220100525
    building in /root/tmp/pear/pear-build-root3SGnje/geoip-1.0.8
    running: /root/tmp/pear/geoip/configure
    checking for grep that handles long lines and -e... /bin/grep
    checking for egrep... /bin/grep -E
    checking for a sed that does not truncate output... /bin/sed
    checking for cc... cc
    checking for C compiler default output file name... a.out
    checking whether the C compiler works... yes
    checking whether we are cross compiling... no
    checking for suffix of executables...
    checking for suffix of object files... o
    checking whether we are using the GNU C compiler... yes
    checking whether cc accepts -g... yes
    checking for cc option to accept ISO C89... none needed
    checking how to run the C preprocessor... cc -E
    checking for icc... no
    checking for suncc... no
    checking whether cc understands -c and -o together... yes
    checking for system library directory... lib
    checking if compiler supports -R... no
    checking if compiler supports -Wl,-rpath,... yes
    checking build system type... x86_64-unknown-linux-gnu
    checking host system type... x86_64-unknown-linux-gnu
    checking target system type... x86_64-unknown-linux-gnu
    checking for PHP prefix... /usr/local
    checking for PHP includes... -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib
    checking for PHP extension directory... /usr/local/lib/php/extensions/no-debug-non-zts-20100525
    checking for PHP installed headers prefix... /usr/local/include/php
    checking if debug is enabled... no
    checking if zts is enabled... no
    checking for re2c... no
    configure: WARNING: You will need re2c 0.13.4 or later if you want to regenerate PHP parsers.
    checking for gawk... gawk
    checking for geoip support... yes, shared
    checking for geoip files in default path... not found
    configure: error: Please reinstall the geoip distribution
    ERROR: `/root/tmp/pear/geoip/configure' failed
    The geoip.so object is not in /usr/local/lib/php/extensions/no-debug-non-zts-20100525
    Tidying /usr/local/lib/php.ini...
    No changes
    Tidying /usr/local/cpanel/3rdparty/php/54/etc/php.ini...
    No changes
     
  8. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,854
    Likes Received:
    676
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
Loading...

Share This Page