Learn about Centmin Mod LEMP Stack today
Register Now

Beta Branch auto patch PHP 7.3.0 for serious Zend Opcache bug

Discussion in 'Centmin Mod Github Commits' started by eva2000, Dec 12, 2018.

  1. eva2000

    eva2000 Administrator Staff Member

    39,815
    8,780
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +13,515
    Local Time:
    4:57 AM
    Nginx 1.15.x
    MariaDB 5.5/10.x
    auto patch PHP 7.3.0 for serious Zend Opcache bug

    - for 123.0beta01, auto patch PHP 7.3.0 for Zend Opcache bug PHP 7.3.0, 7.2.13, 7.1.25, 7.0.33, 5.6.39 Released. The fixes are scheduled for PHP 7.3.1 for non-Centmin Mod systems though while Centmin Mod 123.09beta01 PHP 7.3.0 will get a patch fix via this update
    - patched PHP routines are logged to /root/centminlogs/patch_php_*.log date timestamped logs
    - be sure to updated 123.09beta01 via cmupdate command before re-running centmin.sh menu option 5 to reinstall PHP 7.3.0 if you're using that version

    Continue reading...

    123.09beta01 branch
     
  2. eva2000

    eva2000 Administrator Staff Member

    39,815
    8,780
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +13,515
    Local Time:
    4:57 AM
    Nginx 1.15.x
    MariaDB 5.5/10.x
    example cmupdate for 123.09beta01 code update
    Code (Text):
    cmupdate
    No local changes to save
    Updating 138a600..1f1fe67
    Fast-forward
     inc/php_patch.inc          |  14 +++++++++++++-
     patches/php/77275fix.patch | 135 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
     2 files changed, 148 insertions(+), 1 deletion(-)
     create mode 100644 patches/php/77275fix.patch
    

    and after centmin.sh menu option 5 php 7.3.0 recompile patch log - you can ignore the failed patch of NEWS text file
    Code (Text):
    cat /root/centminlogs/patch_php_111218-180310.log
    
    patching PHP Zend Opcache Bug
    https://bugs.php.net/bug.php?id=77275
    
    dos2unix: converting file 77275fix.patch to Unix format ...
    patching file NEWS
    Hunk #1 FAILED at 33.
    1 out of 1 hunk FAILED -- saving rejects to file NEWS.rej
    patching file Zend/zend_compile.c
    patching file ext/opcache/Optimizer/compact_literals.c
    patching file ext/opcache/Optimizer/zend_optimizer.c
    patching file ext/opcache/tests/bug77275.phpt
    
     
  3. eva2000

    eva2000 Administrator Staff Member

    39,815
    8,780
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +13,515
    Local Time:
    4:57 AM
    Nginx 1.15.x
    MariaDB 5.5/10.x
    testing 77275 bug fix via test
    Code (Text):
    wget -O 77275test.php https://gist.github.com/centminmod/d631afac6859695c1a7e60b3f595e755/raw/77275.php
    php -f 77275test.php
    

    correct output should result in
    Code (Text):
    php -f 77275test.php
    string(1) "a"
    

    incorrect bugged output results in
    Code (Text):
    php -f 77275test.php
    string(1) "b"
    
     
  4. Sunka

    Sunka Well-Known Member

    1,100
    298
    83
    Oct 31, 2015
    Rijeka, Croatia
    Ratings:
    +479
    Local Time:
    8:57 PM
    Nginx 1.15.8
    MariaDB 10.3.12
    So it is safe enough to upgrade to php 7.3.0 with newest 2.0.12 xenforo?
     
  5. eva2000

    eva2000 Administrator Staff Member

    39,815
    8,780
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +13,515
    Local Time:
    4:57 AM
    Nginx 1.15.x
    MariaDB 5.5/10.x
    there seems to be more PHP 7.3.0 bugs being reported in PHP 7.3.1 NEWS change log they're prepping so probably use on test forum only and not production live site/forum as yet. PHP 7.3.1 would contain more bug fixes that this patch I did.
     
    • Informative Informative x 1
  6. pdinh97qng

    pdinh97qng Member

    44
    6
    8
    Jan 24, 2016
    Ratings:
    +10
    Local Time:
    11:57 AM
    :ROFLMAO: I just upgraded to PHP 7.3.0 about a hour ago. As I saw the XenForo 2.0.12 released + this topic in the morning!:cry: Hopefully everything works fine!
     
    • Like Like x 1
  7. eva2000

    eva2000 Administrator Staff Member

    39,815
    8,780
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +13,515
    Local Time:
    4:57 AM
    Nginx 1.15.x
    MariaDB 5.5/10.x
    Use PHP 7.3.0 only on test forum and use PHP 7.2.13 on live forums for now until PHP 7.3.1 is out. This auto patch fix just makes testing Xenforo test forums on PHP 7.3.0 safer but there's probably more bugs in PHP 7.3.0 that will be fixed in 7.3.1
     
    • Informative Informative x 1
  8. pdinh97qng

    pdinh97qng Member

    44
    6
    8
    Jan 24, 2016
    Ratings:
    +10
    Local Time:
    11:57 AM
    Nothing happened yet! And my forum is not to big so it's ok for me now!! I will downgrade back to php 7.2 incase something weird happen
     
  9. eva2000

    eva2000 Administrator Staff Member

    39,815
    8,780
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +13,515
    Local Time:
    4:57 AM
    Nginx 1.15.x
    MariaDB 5.5/10.x
    I'd at least recompile PHP 7.3.0 with above patch fix for Zend Opcache bug as it can cause data loss.
     
    • Like Like x 1
  10. pdinh97qng

    pdinh97qng Member

    44
    6
    8
    Jan 24, 2016
    Ratings:
    +10
    Local Time:
    11:57 AM
    Thank you! I already recompiled. When will you upgrade to XenForo 2.x.x as 1.5 will not receive update in next few months
     
  11. eva2000

    eva2000 Administrator Staff Member

    39,815
    8,780
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +13,515
    Local Time:
    4:57 AM
    Nginx 1.15.x
    MariaDB 5.5/10.x
    • Friendly Friendly x 1
  12. pdinh97qng

    pdinh97qng Member

    44
    6
    8
    Jan 24, 2016
    Ratings:
    +10
    Local Time:
    11:57 AM
    It's end of 2018 now :yuck: Even that XF2 has been out for a while but some add-ons only available in XF1. XF1 still a decent choice for now
     
    • Agree Agree x 1
..