updated php to 5.4.16, mysql suddenly won't load even if running

Discussion in 'Install/Configuration' started by bangsters, Jun 19, 2013.

  1. bangsters

    bangsters Well-Known Member


    I have updated our litespeed server to the latest, and recompiled php to 5.4.16.

    Everything seems to have installed fine, but the server can no longer connect to the mysql database. mysql is running tho....

    any suggestions??
  2. NiteWave

    NiteWave Administrator

    what's your php's compile option ? does it work under apache(if you also run cPanel) ?
  3. bangsters

    bangsters Well-Known Member

    I used the same php compile options as the previous build.

    we are using interworx. everything was working perfectly fine before the php recompile to a newer version.
  4. NiteWave

    NiteWave Administrator

    if complile php use --with-mysql, there is a difference between 5.3 and 5.4
    5.4 --with-mysql is equivalent to 5.3 --with-mysql=mysqlnd

    please provide more information about the issue, ideally others can reproduce it based on your description.
  5. bangsters

    bangsters Well-Known Member

    Hi. I actually have that already in the compile setting, --with-MySQL

    I tried to downgrade back to 5.3.19 and MySQL just worked again. now I put back 5.4.16 and MySQL won't load.....werd...
  6. bangsters

    bangsters Well-Known Member

    ok I recompiled again and downgraded to 5.3.26. Now it can connect again to the database.

    However, another issue has presented itself. When I updated our whmcs installation to the newest, the cronjobs no longer work. I get a segmentation fault. I contacted whmcs support and they say that there is something wrong with my php, eventhough the older version of whmcs works fine, and the other cronjobs work fine.

    below is the error i get:

    php -q /home/account/account.com/html/my/admin/cron.php
    Segmentation fault (core dumped)
  7. NiteWave

    NiteWave Administrator

    check php's full path :
    #which php
  8. bangsters

    bangsters Well-Known Member


    Basically I deleted the original php and created a symlink to lsphp

    I confirmed that the php version running is the one I installed, which is 5.3.26
  9. NiteWave

    NiteWave Administrator

    this is an important clue, trace it, should be able to find out the root cause.

    run "php -i" to find which php.ini is used.
    run "php -c /path/to/your-customized-php.ini /home/account/account.com/html/my/admin/cron.php" until no core dump.

    adjust /path/to/your-customized-php.ini , to remove some extensions.
  10. bangsters

    bangsters Well-Known Member

    I get a syntax error:

    PHP: syntax error, unexpected '&' in /home/account/account.com/html/pop.php on line 4

    But I cannot see the code since it's encoded with ioncube.
  11. bangsters

    bangsters Well-Known Member

    ok got it fixed by copying /usr/local/lsws/lsphp5/bin/php to /usr/bin/ and replacing the other one I used, which is /usr/local/lsws/fcgi-bin/lsphp-5.3.26 (which I copied to /usr/bin/lsphp before)

    Before, I used the lsphp from this folder without issues. I think moving forward I'll be using the one in /usr/local/lsws/lsphp5/ instead.
  12. NiteWave

    NiteWave Administrator

    great! so
    got resolved. how about another one -- " updated php to 5.4.16, mysql suddenly won't load even if running"?
  13. bangsters

    bangsters Well-Known Member

    that one still up in the air. now i'm running on 5.3.26, and won't go into 5.4.xx for a while as there are significant differences I believe, and it will just complicate a lot of things.

    as long as our servers are pci compliant, i'm a happy camper :)

Share This Page