PhpSwitcher ioncube and quota

  • Hello
    I installed and folowed procedure described here : https://wiki.i-mscp.net/doku.php?id=plugins:phpswitcher
    All seems all right and i can switch php versions.
    Yet, i've got to principal problems


    ioncube dont' work anymore (i used to have PHP5.6 and i just install PHP 7 : if i configure as described ioncube seems don't work . but if i try to retrun to PHP 5.6 from the plugin pages, i dont' work anymore as well .
    (of course, it worked before and i restart server each time).


    Is there any other main file i shall configure ?


    As described i'got also DISK QUOT exceed on my VPS (of course i have lot of space avalaible and configure as root) so i can just install on php version more and anything else :( it appear since i install the plugin



    Can you please give me advice ? thx

  • installed and folowed procedure described here : https://wiki.i-mscp.net/doku.php?id=plugins:phpswitcher
    All seems all right and i can switch php versions.
    Yet, i've got to principal problems


    ioncube dont' work anymore (i used to have PHP5.6 and i just install PHP 7 : if i configure as described ioncube seems don't work . but if i try to retrun to PHP 5.6 from the plugin pages, i dont' work anymore as well .
    (of course, it worked before and i restart server each time).

    Describe us the exact steps you following with all commands.


    As described i'got also DISK QUOT exceed on my VPS (of course i have lot of space avalaible and configure as root) so i can just install on php version more and anything else it appear since i install the plugin

    • Be sure to remove older PHP versions from the /opt directory. There is one directory named by date. Pay attention to not remove PHP versions from your last build.
    • Be sure to clean your system: apt-get clean
    • Be sure to remove PhpSwitcher build directory once you have build your PHP versions

    badge.php?id=1239063037&bid=2518&key=1747635596&format=png&z=547451206

  • Bonjour =Laurent, merci de la réponse.


    Describe us the exact steps you following with all commands.


    I folowed the notice:

    Shell-Script
    1. cd /usr/local/src
    2. wget http://downloads3.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz
    3. tar -xzf ioncube_loaders_lin_x86-64.tar.gz
    4. cd ioncube
    5. PHP_EXT_DIR=$(/opt/phpswitcher/%ymd%/php%version%/bin/php-config --extension-dir)
    6. cp ioncube_loader_lin_%version%.so $PHP_EXT_DIR/ioncube.so
    7. echo "zend_extension = $PHP_EXT_DIR/ioncube.so" > /opt/phpswitcher/%ymd%/php%version%/etc/php/conf.d/01_ioncube.ini

    Where version was changed to 7.0 and i replaced ymd of course .
    My old php version was located in /etc/php/5.6 then with the plugin the new php version is located in /opt/phpswitcher . Before installing the opt rep was empty ).

  • @nktine


    I'll give a try in few minutes (compiling PHP 7 and adding ioncube).

    badge.php?id=1239063037&bid=2518&key=1747635596&format=png&z=547451206

  • @nktine


    I cannot confirm the problem. I've tested under Debian Jessie (up-to-date) with i-MSCP 1.4.6 as follow:


    • I've uploaded and installed the PhpSwitcher plugin
    • Ive run the following commands:
    Shell-Script
    1. cd /usr/local/srcINSTALLDIR=/opt/phpswitcher/$(date +'%Y%m%d')PHP_VERSION=7.0perl /var/www/imscp/gui/plugins/PhpSwitcher/PhpCompiler/php_compiler.pl --auto-setup --install-dir $INSTALLDIR --parallel-jobs 10 $PHP_VERSIONwget http://downloads3.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gztar -xzf ioncube_loaders_lin_x86-64.tar.gzcd ioncubePHP_EXT_DIR=$($INSTALLDIR/php$PHP_VERSION/bin/php-config --extension-dir)cp ioncube_loader_lin_$PHP_VERSION.so $PHP_EXT_DIR/ioncube.soecho "zend_extension = $PHP_EXT_DIR/ioncube.so" > $INSTALLDIR/php$PHP_VERSION/etc/php/conf.d/01_ioncube.ini


    Once done, I've do a first check via CLI:

    Shell-Script
    1. root@jessie:/usr/local/src/ioncube# $INSTALLDIR/php$PHP_VERSION/bin/php -v
    2. PHP 7.0.20 (cli) (built: Jun 18 2017 06:44:00) ( NTS )
    3. Copyright (c) 1997-2017 The PHP Group
    4. Zend Engine v3.0.0, Copyright (c) 1998-2017 Zend Technologies
    5. with the ionCube PHP Loader (enabled) + Intrusion Protection from ioncube24.com (unconfigured) v6.1.0 (), Copyright (c) 2002-2017, by ionCube Ltd.
    6. with Zend OPcache v7.0.20, Copyright (c) 1999-2017, by Zend Technologies

    As you can see here, ionCube is loaded as expected.


    Then, as administrator, I've regenerated phpinfo files as it is recommended in the PhpSwitcher plugin documentation
    Then, as customer, I've set the PHP 7.0.20 version for the domain. Result:


    ioncube_01.png


    ioncube_02.png


    ioncube_03.png

    badge.php?id=1239063037&bid=2518&key=1747635596&format=png&z=547451206

  • hello,
    i migrate i-mscp to the latest version, purge tmp archives and try to activate ioncube.
    Seems it not woking for the moment but ioncube seems installed






    yet it worked before in php 5.6 , strange...
    So clearly the plugin do work, i spend time searching incopatbility in ioncube 6.1 and php 7 or my script (but don't find it for the moment)


    Thx for your help anyway

  • @nktine


    You must be sure that your PHP application has been encoded to work with ioncube for PHP 7.

    badge.php?id=1239063037&bid=2518&key=1747635596&format=png&z=547451206