Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

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.

Upgrading PHP when using CloudLinux

Discussion in 'EasyApache' started by random, Oct 25, 2016.

  1. random

    random Member

    Joined:
    May 13, 2004
    Messages:
    14
    Likes Received:
    1
    Trophy Points:
    153
    Hello,

    I would like to upgrade the 'native' version of PHP on the server from 5.4 to 5.6. The server is running CLOUDLINUX 6.8 x86_64 standard – host WHM 58.0 (build 32)

    Some of my clients have used the PHP selector to change the PHP version for their sites to either 5.3, 5.5 or 5.6. Most of these are on 5.3 (perhaps about 20) whilst only 2 or 3 accounts are using 5.5 and 5.6.

    How will it work? When I upgrade PHP in WHM using EasyApache 3, does it mean that all the accounts currently on 'native' setting will automaticallly use the new 'native' PHP version 5.6?

    Will the clients that have used the PHP selector retain the version that they have chosen or will they also be moved to 5.6?

    What is the best (safest for my clients) way to upgrade? Is it enough to simply upgrade PHP via EasyApache and CloudLinux will simply 'adjust itself' to the new version?

    Having never upgraded PHP on a CloudLinux server before, I am not sure about the procedure.

    I have asked the same questions to the CloudLinux people but they have refused to answer, saying this has nothing to do with CloudLinux.

    Thank you.

    Pascal
     
  2. vanessa

    vanessa Well-Known Member
    PartnerNOC

    Joined:
    Sep 26, 2006
    Messages:
    829
    Likes Received:
    25
    Trophy Points:
    178
    Location:
    Virginia Beach, VA
    cPanel Access Level:
    DataCenter Provider
    If I were you, I'd just use the EA4 profile that provides Apache only without PHP, and make sure the correct handlers are installed. We purposely shied away from using the CL PHP selector to prevent issues like this.

    A more complex solution, and one that you may want to consider if you have the means to do so, is to go ahead and install a full EA4 profile and then 'convert' the users to use the corresponding version of PHP provided by cPanel. This will only not work if you have people using PHP 5.3 or older, which is not provided by EA4.
     
  3. random

    random Member

    Joined:
    May 13, 2004
    Messages:
    14
    Likes Received:
    1
    Trophy Points:
    153
    Hello Vanessa,

    Thank you for your reply.

    I am a bit reluctant to upgrade to EA4 at the moment as I have heard there are still some issues to be ironed out. I may be wrong but I would prefer to wait a little longer for that.
     
  4. vanessa

    vanessa Well-Known Member
    PartnerNOC

    Joined:
    Sep 26, 2006
    Messages:
    829
    Likes Received:
    25
    Trophy Points:
    178
    Location:
    Virginia Beach, VA
    cPanel Access Level:
    DataCenter Provider
    If you're not upgrading to EA4, just run easyapache as normal. I've never seen it cause an issue with CL's PHP selector.
     
  5. random

    random Member

    Joined:
    May 13, 2004
    Messages:
    14
    Likes Received:
    1
    Trophy Points:
    153
    I was hoping it might be as simple as that. Thank you.
     
  6. easyswiss

    easyswiss Active Member

    Joined:
    Apr 19, 2011
    Messages:
    37
    Likes Received:
    0
    Trophy Points:
    56
    Attention: There is a bug in the cPanel v. 58 Build 32

    Reconstruction: Fresh system with cPanel + Cloudlinux + CageFS + PHP Selector

    1) Run Easyapache 4 to add as example "env"
    2) PHP Selector is ignored.

    Fix it...

    Run Easyapache 4 again.
    Same issue
     
  7. easyswiss

    easyswiss Active Member

    Joined:
    Apr 19, 2011
    Messages:
    37
    Likes Received:
    0
    Trophy Points:
    56
    No it is not addressed. They said yesterday.. yes you can run easyapache 4 in cpanel.. now same... php selector offline means all websites with an internal error 500:

    Attention: There is a bug in the cPanel v. 58 Build 32

    Reconstruction: Fresh system with cPanel + Cloudlinux + CageFS + PHP Selector

    1) Run Easyapache 4 to add as example "env"
    2) PHP Selector is ignored.

    Fix it... with a console build
    Code:
    /usr/local/bin/ea_install_profile --install /etc/cpanel/ea4/profiles/vendor/cloudlinux/allphp_cl_lsapi.json
    Run Easyapache 4 again.
    Same issue
     
  8. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    38,658
    Likes Received:
    1,425
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Hello,

    Could you let us know the output from /usr/local/apache/logs/error_log when your websites display the "500" internal server error? Also, you are welcome to open a support ticket using the link in my signature so we can take a closer look. Ensure you post the ticket number here if you choose to do so.

    Documentation regarding the use of PHP Selector with EasyApache 4 is offered at:

    PHP Selector > Control Panel Integration > cPanel

    In particular, here's a quote from this document regarding inherit setting:

    Thank you.
     
  9. easyswiss

    easyswiss Active Member

    Joined:
    Apr 19, 2011
    Messages:
    37
    Likes Received:
    0
    Trophy Points:
    56
    Hello here is the log (17:27 is the time i was clicking on the "Easyapache 4 Button in cpanel"

    Code:
    [Tue Oct 25 17:27:54.862253 2016] [:notice] [pid 284607:tid 139804960446432] mod_hostinglimits: use Min UID 500
    [Tue Oct 25 17:27:54.862310 2016] [:notice] [pid 284607:tid 139804960446432] mod_hostinglimits: use filter for LVE exit
    [Tue Oct 25 17:27:54.862314 2016] [:notice] [pid 284607:tid 139804960446432] mod_hostinglimits: version 1.0-27. LVE mechanism enabled
    [Tue Oct 25 17:27:54.862318 2016] [:notice] [pid 284607:tid 139804960446432] mod_hostinglimits: found apr extention version 3
    [Tue Oct 25 17:27:54.862321 2016] [:notice] [pid 284607:tid 139804960446432] mod_hostinglimits: apr_lve_environment_init_group_minuid check ok
    [Tue Oct 25 17:27:54.863674 2016] [ssl:warn] [pid 284607:tid 139804960446432] AH01909: XXXX:443:0 server certificate does NOT include an ID which matches the server name
    [Tue Oct 25 17:27:54.863835 2016] [:notice] [pid 284607:tid 139804960446432] ModSecurity for Apache/2.9.0 (http://www.modsecurity.org/) configured.
    [Tue Oct 25 17:27:54.863841 2016] [:notice] [pid 284607:tid 139804960446432] ModSecurity: APR compiled version="1.5.2"; loaded version="1.5.2"
    [Tue Oct 25 17:27:54.863846 2016] [:notice] [pid 284607:tid 139804960446432] ModSecurity: PCRE compiled version="7.8 "; loaded version="7.8 2008-09-05"
    [Tue Oct 25 17:27:54.863849 2016] [:notice] [pid 284607:tid 139804960446432] ModSecurity: LUA compiled version="Lua 5.1"
    [Tue Oct 25 17:27:54.863852 2016] [:notice] [pid 284607:tid 139804960446432] ModSecurity: LIBXML compiled version="2.7.6"
    [Tue Oct 25 17:27:54.863855 2016] [:notice] [pid 284607:tid 139804960446432] ModSecurity: Status engine is currently disabled, enable it by set SecStatusEngine to On.
    [Tue Oct 25 17:27:54.864300 2016] [suexec:notice] [pid 284607:tid 139804960446432] AH01232: suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
    [Tue Oct 25 17:27:54.887361 2016] [:notice] [pid 284608:tid 139804960446432] mod_hostinglimits: use Min UID 500
    [Tue Oct 25 17:27:54.887390 2016] [:notice] [pid 284608:tid 139804960446432] mod_hostinglimits: use filter for LVE exit
    [Tue Oct 25 17:27:54.887394 2016] [:notice] [pid 284608:tid 139804960446432] mod_hostinglimits: version 1.0-27. LVE mechanism enabled
    [Tue Oct 25 17:27:54.887398 2016] [:notice] [pid 284608:tid 139804960446432] mod_hostinglimits: found apr extention version 3
    [Tue Oct 25 17:27:54.887403 2016] [:notice] [pid 284608:tid 139804960446432] mod_hostinglimits: apr_lve_environment_init_group_minuid check ok
    [Tue Oct 25 17:27:54.888845 2016] [ssl:warn] [pid 284608:tid 139804960446432] AH01909: XXXX:443:0 server certificate does NOT include an ID which matches the server name
    [Tue Oct 25 17:27:54.890758 2016] [lsapi:notice] [pid 284608:tid 139804960446432] mod_lsapi:  version 1.0-17 Connection pool mode is switched off
    [Tue Oct 25 17:27:54.891363 2016] [:notice] [pid 284611:tid 139804960446432] [host XXXX] mod_lsapi:  Selfstarter 284611 started
    [Tue Oct 25 17:27:54.896768 2016] [mpm_worker:notice] [pid 284608:tid 139804960446432] AH00292: Apache/2.4.23 (cPanel) OpenSSL/1.0.1e-fips mod_bwlimited/1.4 configured -- resuming normal operations
    [Tue Oct 25 17:27:54.896797 2016] [core:notice] [pid 284608:tid 139804960446432] AH00094: Command line: '/usr/sbin/httpd'
    PHP Warning:  PHP Startup: Unable to load dynamic library '/opt/cpanel/ea-php70/root/usr/lib64/php/modules/calendar.so' - /opt/cpanel/ea-php70/root/usr/lib64/php/modules/calendar.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 '/opt/cpanel/ea-php70/root/usr/lib64/php/modules/gmp.so' - /opt/cpanel/ea-php70/root/usr/lib64/php/modules/gmp.so: cannot open shared object file: No such file or directory in Unknown on line 0
    [Tue Oct 25 18:24:24.061569 2016] [mpm_worker:notice] [pid 284608:tid 139804960446432] AH00297: SIGUSR1 received.  Doing graceful restart
    [Tue Oct 25 18:24:24.564060 2016] [:notice] [pid 284611:tid 139804960446432] [host XXXX] mod_lsapi:  Selfstarter 284611 stopped
    [Tue Oct 25 18:24:24.588628 2016] [:notice] [pid 284608:tid 139804960446432] mod_hostinglimits: use Min UID 500
    [Tue Oct 25 18:24:24.588656 2016] [:notice] [pid 284608:tid 139804960446432] mod_hostinglimits: use filter for LVE exit
    [Tue Oct 25 18:24:24.588659 2016] [:notice] [pid 284608:tid 139804960446432] mod_hostinglimits: version 1.0-27. LVE mechanism enabled
    [Tue Oct 25 18:24:24.588664 2016] [:notice] [pid 284608:tid 139804960446432] mod_hostinglimits: found apr extention version 3
    [Tue Oct 25 18:24:24.588668 2016] [:notice] [pid 284608:tid 139804960446432] mod_hostinglimits: apr_lve_environment_init_group_minuid check ok
    [Tue Oct 25 18:24:24.590069 2016] [ssl:warn] [pid 284608:tid 139804960446432] AH01909: XXXX:443:0 server certificate does NOT include an ID which matches the server name
    [Tue Oct 25 18:24:24.591826 2016] [lsapi:notice] [pid 284608:tid 139804960446432] mod_lsapi:  version 1.0-17 Connection pool mode is switched off
    [Tue Oct 25 18:24:24.592381 2016] [:notice] [pid 296803:tid 139804960446432] [host XXXX] mod_lsapi:  Selfstarter 296803 started
    [Tue Oct 25 18:24:24.592426 2016] [mpm_worker:notice] [pid 284608:tid 139804960446432] AH00292: Apache/2.4.23 (cPanel) OpenSSL/1.0.1e-fips mod_bwlimited/1.4 configured -- resuming normal operations
    [Tue Oct 25 18:24:24.592438 2016] [core:notice] [pid 284608:tid 139804960446432] AH00094: Command line: '/usr/sbin/httpd'
    PHP Warning:  PHP Startup: Unable to load dynamic library '/opt/cpanel/ea-php70/root/usr/lib64/php/modules/calendar.so' - /opt/cpanel/ea-php70/root/usr/lib64/php/modules/calendar.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 '/opt/cpanel/ea-php70/root/usr/lib64/php/modules/gmp.so' - /opt/cpanel/ea-php70/root/usr/lib64/php/modules/gmp.so: cannot open shared object file: No such file or directory in Unknown on line 0
    [Tue Oct 25 18:30:49.796135 2016] [mpm_worker:notice] [pid 284608:tid 139804960446432] AH00297: SIGUSR1 received.  Doing graceful restart
     
  10. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    38,658
    Likes Received:
    1,425
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Hello,

    This suggests you are missing a couple of PHP modules for PHP 7. You can use the following commands to install these modules:

    Code:
    yum install ea-php70-php-calendar
    yum install ea-php70-php-gmp
    If this doesn't help, open a support ticket using the link in my signature so we can take a closer look.

    Thank you.
     
Loading...

Share This Page