Welcome to Centmin Mod Community
Become a Member

Beta Branch update PHP routine for renamed oniguruma5php packages in 123.09beta01

Discussion in 'Centmin Mod Github Commits' started by eva2000, Jun 12, 2020.

  1. eva2000

    eva2000 Administrator Staff Member

    55,155
    12,249
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,825
    Local Time:
    6:19 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    update PHP routine for renamed oniguruma5php packages in 123.09beta01

    - REMI YUM packages oniguruma5 have been renamed upstream to oniguruma5php which breaks PHP 7.4 upgrade/compiles on fresh initial Centmin Mod installed servers as oniguruma5 packages no longer exist
    - Existing Centmin Mod users, run cmupdate to update 123.09beta01 code before running centmin.sh menu option 5

    Continue reading...

    123.09beta01 branch


     
  2. pamamolf

    pamamolf Premium Member Premium Member

    4,100
    428
    83
    May 31, 2014
    Ratings:
    +836
    Local Time:
    11:19 PM
    Nginx-1.26.x
    MariaDB 10.6.x
    If you run the cmupdate and then update using:

    Code:
    yum update --disableplugin=priorities --setopt=deltarpm=0 --enablerepo=remi,city-fan.org
    it will replace the oniguruma5.x86_64 and oniguruma5-devel.x86_64 with oniguruma5php and oniguruma5php-devel and if you try to restart php you will get this error:

    Code:
    /usr/local/sbin/php-fpm: error while loading shared libraries: libonig.so.5: cannot open shared object file: No such file or directory
    Php will not start...

    I am recompiling now to check it.... :)
     
  3. pamamolf

    pamamolf Premium Member Premium Member

    4,100
    428
    83
    May 31, 2014
    Ratings:
    +836
    Local Time:
    11:19 PM
    Nginx-1.26.x
    MariaDB 10.6.x
    After recompiling all seems to work again :)

    So it seems that after updating Centminmod and system we must recompile php to all be ok :)

    Just a note ....
     
  4. eva2000

    eva2000 Administrator Staff Member

    55,155
    12,249
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,825
    Local Time:
    6:19 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    that is indeed a tricky one ! though normal yum date won't enable --enablerepo=remi so won't update onigurama5php packages unless you do it after centmin.sh menu option 24 exit prompt
     
  5. pamamolf

    pamamolf Premium Member Premium Member

    4,100
    428
    83
    May 31, 2014
    Ratings:
    +836
    Local Time:
    11:19 PM
    Nginx-1.26.x
    MariaDB 10.6.x
    If i run cmupdate and recompile/update php before the system update from menu 24 option it will auto replace the oniguruma5.x86_64 ?
     
  6. eva2000

    eva2000 Administrator Staff Member

    55,155
    12,249
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,825
    Local Time:
    6:19 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    yup :)
     
  7. pamamolf

    pamamolf Premium Member Premium Member

    4,100
    428
    83
    May 31, 2014
    Ratings:
    +836
    Local Time:
    11:19 PM
    Nginx-1.26.x
    MariaDB 10.6.x
    Is oniguruma5 for php 7.4.x only ?
     
  8. Jimmy

    Jimmy Well-Known Member

    1,788
    390
    83
    Oct 24, 2015
    East Coast USA
    Ratings:
    +990
    Local Time:
    4:19 PM
    Got the same thing. Weirdness happened with IPS, cron seems to stop working as I got warnings in the backend about tasks backing up in queue. When I restarted PHP got the libonig.so.5 error and a 502 bad gateway error on the site(s).

    Got an error when building php - upgrading to 7.4.7.

    Code:
    Do you want to run YUM install checks ?  [y/n]
    
    This will increase your upgrade duration time wise.
    Check the change log centminmod.com/changelog.html
    to see if any Nginx or PHP related new additions
    which require checking YUM prequisites are met.
    If no new additions made, you can skip the
    YUM install check to speed up upgrade time.
    
     [y/n]: n
         ____   _   _  ____       _   _                                _     
        |  _ \ | | | ||  _ \  _  | | | | _ __    __ _  _ __  __ _   __| |  ___
        | |_) || |_| || |_) |(_) | | | || '_ \  / _` || '__|/ _` | / _` | / _ \
        |  __/ |  _  ||  __/  _  | |_| || |_) || (_| || |  | (_| || (_| ||  __/
        |_|    |_| |_||_|    (_)  \___/ | .__/  \__, ||_|   \__,_| \__,_| \___|
                                        |_|     |___/                       
     
    PHP Upgrade/Downgrade - Would you like to continue? [y/n] y
    
    ----------------------------------------------------------------
    Install which version of PHP? (version i.e. 5.6.40, 7.0.33, NGDEBUG)
    PHP 7.x/7.1.x/7.2.x/7.3.x is GA Stable but still may have broken PHP extensions.
    NGDEBUG is PHP 8.0 dev builds minus incompatible PHP extensions
    ----------------------------------------------------------------
    
    Current PHP Version: error
    
    Enter PHP Version number you want to upgrade/downgrade to: 7.4.7
    
    Do you still want to continue? [y/n] y
    
    ----------------------------------------------------------------
    existing php.ini will be backed up at /usr/local/lib/php.ini-oldversion_160620-003337
    ----------------------------------------------------------------
    php: error while loading shared libraries: libonig.so.5: cannot open shared object file: No such file or directory
    php: error while loading shared libraries: libonig.so.5: cannot open shared object file: No such file or directory
    
    -----------------------------------------------------------------------------------------
    Detected PHP 7.4 branch.
    You can compile Zend OPcache (Zend Optimizer Plus+) support
    as an alternative to using APC Cache or Xcache cache.
    But Zend OPcache only provides PHP opcode cache and
    DOESN'T do data caching, so if your web apps such as Wordpress,
    Drupal or vBulletin require data caching to APC or Xcache,
    it won't work with Zend OPcache.
    
    -----------------------------------------------------------------------------------------
    Do you want to use Zend OPcache [y/n] ? y
    
    Rebuilding php now, will take a bit to do and will report back if it clears up.

    ------------------

    Rebuild cleared up the issue.
     
    Last edited: Jun 16, 2020
  9. eva2000

    eva2000 Administrator Staff Member

    55,155
    12,249
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,825
    Local Time:
    6:19 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    Yeah that is the solution. Did you do a manual yum update with --enablerepo=remi flag in between periods of centmin.sh menu option 5 runs ? it's only time oniguruma5php package name change would come into effect and would of been taken care of via centmin.sh menu option 5 php upgrades usually
     
  10. Jimmy

    Jimmy Well-Known Member

    1,788
    390
    83
    Oct 24, 2015
    East Coast USA
    Ratings:
    +990
    Local Time:
    4:19 PM
    No I didn't do the enablerepo=remi flag in between periods of centmin.sh menu option 5 runs. I recompiled both nginx and php and everything is working.
     
  11. eva2000

    eva2000 Administrator Staff Member

    55,155
    12,249
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,825
    Local Time:
    6:19 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    strange then as if you didn't do yum updates, then older oniguruma5-devel package would be in place
     
  12. pamamolf

    pamamolf Premium Member Premium Member

    4,100
    428
    83
    May 31, 2014
    Ratings:
    +836
    Local Time:
    11:19 PM
    Nginx-1.26.x
    MariaDB 10.6.x
    After updating to latest php 7.3.x using the cmupdate first and then menu option 5 all working great....

    At the end i got some system updates at exit using menu option 24 and i notice this:

    Code:
    Updating   : oniguruma-6.8.2-1.el7.x86_64
    i thought it should say something like the above but with php at the end of the name.... or not?

    Actually it shouldn't have any updates as it just got installed by the option 5....

    Is it ok ?

    Tested on Centos 7
     
    Last edited: Jul 11, 2020
  13. eva2000

    eva2000 Administrator Staff Member

    55,155
    12,249
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,825
    Local Time:
    6:19 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    It's okay as for existing users you end up with oniguruma-6.8.2 and onigurumaphp-6.9.5 and onigurumaphp-6.9.5-devel so 3 packages installed where PHP uses the latter 2