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.

phpize command not found

Discussion in 'EasyApache' started by amitsonkhiya, Aug 22, 2016.

Tags:
  1. amitsonkhiya

    amitsonkhiya Registered

    Joined:
    Jul 11, 2014
    Messages:
    4
    Likes Received:
    1
    Trophy Points:
    1
    cPanel Access Level:
    Website Owner
    Hi everyone!

    I'm facing the exactly similar issue as mentioned in link cannot install PECL PHPRedis with PHP 5.6 and according to solution suggested I manually tried that with SSH but ending with
    phpize: command not found

    Code:
    [root@vps ~]# cd /usr/local/
    [root@vps local]# wget  https://pecl.php.net/get/redis-2.2.8.tgz
    --2016-08-21 21:13:00--  https://pecl.php.net/get/redis-2.2.8.tgz
    Resolving pecl.php.net... 104.236.228.160
    Connecting to pecl.php.net|104.236.228.160|:443... connected.
    HTTP request sent, awaiting response... 200 OK
    Length: 192131 (188K) [application/octet-stream]
    Saving to: “redis-2.2.8.tgz”
    
    100%[======================================>] 192,131      192K/s   in 1.0s
    
    2016-08-21 21:13:02 (192 KB/s) - “redis-2.2.8.tgz” saved [192131/192131]
    
    [root@vps local]# tar zxpf redis*
    [root@vps local]# cd redis*
    [root@vps redis-2.2.8]# phpize
    -bash: phpize: command not found
    Now what I could understand that the issue is with phpize which requires php-devel module to work but in EasyApache I can see that ea-php56-php-devel is already installed. So can anyone please update me with the exact way to run phpize so that I can install php pecl extension for redis in version 5.6
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,767
    Likes Received:
    662
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello,

    EasyApache 4 includes support for multiple versions of PHP, so you must utilize the PHP SCL specific to a version of PHP when using the command line. For instance, if you wanted to use the "phpize" command for PHP 5.6, you would use the full path:

    Code:
    /opt/cpanel/ea-php56/root/usr/bin/phpize
    Thank you.
     
  3. inetbizo

    inetbizo Well-Known Member

    Joined:
    Mar 28, 2008
    Messages:
    72
    Likes Received:
    0
    Trophy Points:
    6
    Location:
    New Smyrna Beach, FL US
    cPanel Access Level:
    Root Administrator
    Twitter:
    You guys really need to get these into the /etc/bashrc as aliases to the real command in CP 60.x
     
  4. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,767
    Likes Received:
    662
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello @inetbizo,

    It's possible to define a specific PHP version in bash via a command such as:

    Code:
    scl enable ea-php70 bash
    For instance, if you ran this command, "phpize" would then automatically link to the following location from the command line during your bash session:

    Code:
    /opt/cpanel/ea-php70/root/usr/bin/phpize
    The downside of automatically making this the default behavior is that users could then run "phpize" and not understand why it's applied to a PHP version different to what was intended. That said, I encourage you to open a feature request if it's something you'd like us to consider:

    Submit A Feature Request

    Thank you.
     
Loading...

Share This Page