Learn about Centmin Mod LEMP Stack today
Become a Member

Install ioncube

Discussion in 'Add Ons' started by dooma, Oct 24, 2016.

  1. dooma

    dooma Premium Member Premium Member

    222
    22
    18
    Oct 15, 2016
    Cairo
    Ratings:
    +27
    Local Time:
    10:35 PM
    Hello,

    I'm trying to install ioncube on my server. First, I tried the script installer METHOD 2 found here but it gives me these errors:
    Then I tried your method found here and I run this script successfully :
    Code:
    wget https://gist.githubusercontent.com/centminmod/e6454678e96687e97842/raw -O ioncube.sh
    chmod +x ioncube.sh
    ./ioncube.sh
    In the beggining the site was giving me this error :
    Fatal error: The file /home/service/public_html/billing/index.php cannot be decoded by this version of the ionCube Loader. If you are the administrator of this site then please install the latest version of the ionCube Loader. in Unknown on line 0

    But now when I go to mysite.com/billing, I found it down although the other parts at website are running and not down.

    **I upgraded to php 7.

    Thanks
     
  2. eva2000

    eva2000 Administrator Staff Member

    28,984
    6,579
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +9,766
    Local Time:
    6:35 AM
    Nginx 1.13.x
    MariaDB 5.5
    which version of centmin mod 123.08stable or 123.09beta01 ?

    which version of php ?

    Centmin Mod 123.09beta01 addons/ioncube.sh is the most up to date version might try that instead

    Code (Text):
    cd /usr/local/src/centminmod/addons
    ./ioncube.sh
     
  3. dooma

    dooma Premium Member Premium Member

    222
    22
    18
    Oct 15, 2016
    Cairo
    Ratings:
    +27
    Local Time:
    10:35 PM
    I'm using stable version.
     
  4. dooma

    dooma Premium Member Premium Member

    222
    22
    18
    Oct 15, 2016
    Cairo
    Ratings:
    +27
    Local Time:
    10:35 PM
    I tried the previous code and it installed but this part /billing still down.
     
  5. eva2000

    eva2000 Administrator Staff Member

    28,984
    6,579
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +9,766
    Local Time:
    6:35 AM
    Nginx 1.13.x
    MariaDB 5.5
    did you restart nginx and php-fpm ?
    Code (Text):
    nprestart

    123.08stable addons/ioncube.sh is not as up to date as 123.09beta01 addons/ioncube.sh as latter version supports PHP 7 and 5.x and sets the right ioncube loader for PHP versions
     
  6. dooma

    dooma Premium Member Premium Member

    222
    22
    18
    Oct 15, 2016
    Cairo
    Ratings:
    +27
    Local Time:
    10:35 PM
    Still down, do you suggest to upgrade ?
     
  7. eva2000

    eva2000 Administrator Staff Member

    28,984
    6,579
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +9,766
    Local Time:
    6:35 AM
    Nginx 1.13.x
    MariaDB 5.5
    to disable ioncube, you can remove the ioncube.ini settings file and restart php-fpm service. See below for specifics.

    The command below lists all custom PHP extensions' ini file paths for extensions added by Centmin Mod specifically
    Code (Text):
    php --ini


    Find the /etc/centminmod/php.d/ioncube.ini path file and delete it and restart PHP-FPM service

    example output to find redis.ini path
    Code (Text):
    php --ini
    Configuration File (php.ini) Path: /usr/local/lib
    Loaded Configuration File: /usr/local/lib/php.ini
    Scan for additional .ini files in: /etc/centminmod/php.d
    Additional .ini files parsed: /etc/centminmod/php.d/a_customphp.ini,
    /etc/centminmod/php.d/curlcainfo.ini,
    /etc/centminmod/php.d/geoip.ini,
    /etc/centminmod/php.d/igbinary.ini,
    /etc/centminmod/php.d/imagick.ini,
    /etc/centminmod/php.d/memcache.ini,
    /etc/centminmod/php.d/memcached.ini,
    /etc/centminmod/php.d/mongodb.ini,
    /etc/centminmod/php.d/redis.ini,
    /etc/centminmod/php.d/suhosin.ini

    then delete ioncube.ini file
    Code (Text):
    rm /etc/centminmod/php.d/ioncube.ini
    

    restart PHP
    Code (Text):
    service php-fpm restart

    or with command shortcut
    Code (Text):
    fpmrestart
     
  8. eva2000

    eva2000 Administrator Staff Member

    28,984
    6,579
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +9,766
    Local Time:
    6:35 AM
    Nginx 1.13.x
    MariaDB 5.5
    which version of php ? as 123.08stable addons/ioncube.sh doesn't support php 7, only 123.09beta01's addons/ioncube.sh does
     
  9. dooma

    dooma Premium Member Premium Member

    222
    22
    18
    Oct 15, 2016
    Cairo
    Ratings:
    +27
    Local Time:
    10:35 PM
    ok, so now the solution is to upgrade to the beta1 not deleting the ioncube file, correct ?
     
  10. eva2000

    eva2000 Administrator Staff Member

    28,984
    6,579
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +9,766
    Local Time:
    6:35 AM
    Nginx 1.13.x
    MariaDB 5.5
  11. dooma

    dooma Premium Member Premium Member

    222
    22
    18
    Oct 15, 2016
    Cairo
    Ratings:
    +27
    Local Time:
    10:35 PM
    Regarding the update : I choosed menu 23 then submenu 1 to setup Github local environment, then when I choosed submenu 3 I got this error :
    fatal: Unable to read current working directory: No such file or directory
    123.09beta01 branch does not exists
    try again...
     
  12. eva2000

    eva2000 Administrator Staff Member

    28,984
    6,579
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +9,766
    Local Time:
    6:35 AM
    Nginx 1.13.x
    MariaDB 5.5
  13. dooma

    dooma Premium Member Premium Member

    222
    22
    18
    Oct 15, 2016
    Cairo
    Ratings:
    +27
    Local Time:
    10:35 PM
    update completed .. now I should run the previous ioncube .. correct ?
     
  14. eva2000

    eva2000 Administrator Staff Member

    28,984
    6,579
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +9,766
    Local Time:
    6:35 AM
    Nginx 1.13.x
    MariaDB 5.5
    well run the 123.09beta01 version
    Code (Text):
    cd /usr/local/src/centminmod/addons
    ./ioncube.sh
     
  15. dooma

    dooma Premium Member Premium Member

    222
    22
    18
    Oct 15, 2016
    Cairo
    Ratings:
    +27
    Local Time:
    10:35 PM
    This part /billing goes down again? although the ioncube was installed.
     
  16. eva2000

    eva2000 Administrator Staff Member

    28,984
    6,579
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +9,766
    Local Time:
    6:35 AM
    Nginx 1.13.x
    MariaDB 5.5
    What billing software ? and what version of ioncube was the billing software's php encoded with as limitation with PHP 7 is ioncube loader needs to have php files encoded with PHP 5.6+ or higher ioncube loader Addon [beta] | Centmin Mod Community
    also what's output for
    Code (Text):
    php -v

    Might want to use CODE tags for code How to use forum BBCODE code tags :)
     
  17. dooma

    dooma Premium Member Premium Member

    222
    22
    18
    Oct 15, 2016
    Cairo
    Ratings:
    +27
    Local Time:
    10:35 PM
    Clientexec. They require at least Ioncube 4.4.1. .

    The output is :
    Code:
    PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/extensions/no-debug-non-zts-20151012/mongo.so' - /usr/local/lib/php/extensions/no-debug-non-zts-20151012/mongo.so: cannot open shared object file: No such file or directory in Unknown on line 0
    PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/extensions/no-debug-non-zts-20151012/redis.so' - /usr/local/lib/php/extensions/no-debug-non-zts-20151012/redis.so: cannot open shared object file: No such file or directory in Unknown on line 0
    PHP 7.0.0 (cli) (built: Oct 22 2016 01:44:53) ( NTS )
    Copyright (c) 1997-2015 The PHP Group
    Zend Engine v3.0.0, Copyright (c) 1998-2015 Zend Technologies
        with the ionCube PHP Loader (enabled) + Intrusion Protection from ioncube24.com (unconfigured) v6.0.5, Copyright (c) 2002-2016, by ionCube Ltd.
        with Zend OPcache v7.0.6-dev, Copyright (c) 1999-2015, by Zend Technologies
    
    Thanks a lot :)
     
  18. eva2000

    eva2000 Administrator Staff Member

    28,984
    6,579
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +9,766
    Local Time:
    6:35 AM
    Nginx 1.13.x
    MariaDB 5.5
    • If you get some PHP warnings that some PHP extensions are unable to load, all you need to do is delete the relevant *.ini files for them and then reinstall if you require the PHP extension
    Example of error on restart PHP-FPM
    Code (Text):
    fpmrestart
    Gracefully shutting down php-fpm . done
    Starting php-fpm [06-Nov-2014 01:25:37] NOTICE: PHP message: PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/extensions/no-debug-non-zts-20140815/geoip.so' - /usr/local/lib/php/extensions/no-debug-non-zts-20140815/geoip.so: cannot open shared object file: No such file or directory in Unknown on line 0
    [06-Nov-2014 01:25:37] NOTICE: PHP message: PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/extensions/no-debug-non-zts-20140815/igbinary.so' - /usr/local/lib/php/extensions/no-debug-non-zts-20140815/igbinary.so: cannot open shared object file: No such file or directory in Unknown on line 0
    [06-Nov-2014 01:25:37] NOTICE: PHP message: PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/extensions/no-debug-non-zts-20140815/imagick.so' - /usr/local/lib/php/extensions/no-debug-non-zts-20140815/imagick.so: cannot open shared object file: No such file or directory in Unknown on line 0
    [06-Nov-2014 01:25:37] NOTICE: PHP message: PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/extensions/no-debug-non-zts-20140815/memcache.so' - /usr/local/lib/php/extensions/no-debug-non-zts-20140815/memcache.so: cannot open shared object file: No such file or directory in Unknown on line 0
    [06-Nov-2014 01:25:37] NOTICE: PHP message: PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/lib/php/extensions/no-debug-non-zts-20140815/memcached.so' - /usr/local/lib/php/extensions/no-debug-non-zts-20140815/memcached.so: cannot open shared object file: No such file or directory in Unknown on line 0
    done
    

    find the paths to the *.ini files
    Code (Text):
    php --ini 2>/devnull
    Configuration File (php.ini) Path: /usr/local/lib
    Loaded Configuration File:         /usr/local/lib/php.ini
    Scan for additional .ini files in: /etc/centminmod/php.d
    Additional .ini files parsed:      /etc/centminmod/php.d/curlcainfo.ini,
    /etc/centminmod/php.d/custom_php.ini,
    /etc/centminmod/php.d/geoip.ini,
    /etc/centminmod/php.d/igbinary.ini,
    /etc/centminmod/php.d/imagick.ini,
    /etc/centminmod/php.d/memcache.ini,
    /etc/centminmod/php.d/memcached.ini,
    /etc/centminmod/php.d/zendopcache.ini
    

    delete ones that are reported as unable to load so if geoip.so, igbinary.so, imagick.so, memcache.so and memcached.so are reported as unable to load, remove their respective *.ini files
    Code (Text):
    rm -rf /etc/centminmod/php.d/geoip.ini
    rm -rf /etc/centminmod/php.d/igbinary.ini
    rm -rf /etc/centminmod/php.d/imagick.ini
    rm -rf /etc/centminmod/php.d/memcache.ini
    rm -rf /etc/centminmod/php.d/memcached.ini
    

    so in your specific case remove mongodb.ini and redis.ini
    Code (Text):
    rm -rf /etc/centminmod/php.d/redis.ini
    rm -rf /etc/centminmod/php.d/mongodb.ini
    

    then restart PHP-FPM again
    Code (Text):
    fpmrestart
    Gracefully shutting down php-fpm . done
    Starting php-fpm  done
    



    Manually reinstall PHP extension



    for 123.09beta01 - menu options 7, 9, 10, 12, 13 (for redis), 15, 18, and 19 are relevant menu options that can be used only if the specific PHP extension is reporting as unable to load

    in your case only need to reinstall redis php extension via centmin.sh menu option 13
    Code (Text):
    --------------------------------------------------------
         Centmin Mod Menu 123.09beta01 centminmod.com 
    --------------------------------------------------------
    1).  Centmin Install
    2).  Add Nginx vhost domain
    3).  NSD setup domain name DNS
    4).  Nginx Upgrade / Downgrade
    5).  PHP Upgrade / Downgrade
    6).  XCache Re-install
    7).  APC Cache Re-install
    8).  XCache Install
    9).  APC Cache Install
    10). Memcached Server Re-install
    11). MariaDB 5.2/5.5 & 10.x Upgrade Sub-Menu
    12). Zend OpCache Install/Re-install
    13). Install/Reinstall Redis PHP Extension
    14). SELinux disable
    15). Install/Reinstall ImagicK PHP Extension
    16). Change SSHD Port Number
    17). Multi-thread compression: pigz,pbzip2,lbzip2...
    18). Suhosin PHP Extension install
    19). Install FFMPEG and FFMPEG PHP Extension
    20). NSD Install/Re-Install
    21). Update - Nginx + PHP-FPM + Siege
    22). Add Wordpress Nginx vhost + Cache Plugin
    23). Update Centmin Mod Code Base
    24). Exit
    --------------------------------------------------------
    Enter option [ 1 - 24 ]
    



    btw, PHP 7.0.12 is latest version so might want to update via centmin.sh menu option 5
    might want to check with them the latest ioncube version they support

    you can find version you installed via command
    Code (Text):
    php -v
    
     
  19. dooma

    dooma Premium Member Premium Member

    222
    22
    18
    Oct 15, 2016
    Cairo
    Ratings:
    +27
    Local Time:
    10:35 PM
    Trying WHMCS after updating centminmod and then installing ioncube and the installtion page can't be find(down). ?? Thanks
     
  20. dooma

    dooma Premium Member Premium Member

    222
    22
    18
    Oct 15, 2016
    Cairo
    Ratings:
    +27
    Local Time:
    10:35 PM
    Suddenly, The FTP stopped working ?! and Could not connect to server.!