Welcome to Centmin Mod Community
Become a Member

Beta Branch prep for PHP 8.2.0alpha/beta/rc versions in 130.00beta01

Discussion in 'Centmin Mod Github Commits' started by eva2000, Jun 11, 2022.

  1. eva2000

    eva2000 Administrator Staff Member

    59,366
    12,510
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +19,145
    Local Time:
    8:23 AM
    Nginx 1.31.x
    MariaDB 10.x/11.4+/12.3+
    prep for PHP 8.2.0alpha/beta/rc versions in 130.00beta01

    - fix PHP 7/8 detection bug
    - prep for supporting PHP 8.2.0 alpha/beta/rc versions with first release of 8.2.0alpha1 version https://www.php.net/archive/2022.php#2022-06-09-3. You'll need to specify version as 8.2.0alpha1 in centmin.sh menu option 5
    - not all PHP extensions and routines will support PHP 8.2 right now in it's alpha state. So not advisable for use on production live sites.


    Continue reading...

    130.00beta01 branch
     
  2. eva2000

    eva2000 Administrator Staff Member

    59,366
    12,510
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +19,145
    Local Time:
    8:23 AM
    Nginx 1.31.x
    MariaDB 10.x/11.4+/12.3+
    Only a few PHP extensions not working with PHP 8.2.0alpha1, optional MongoDB and swoole PHP extensions. With swoole error, need to remove swoole.ini and restart PHP-FPM service for now
    Code (Text):
    php -v
    PHP Warning:  PHP Startup: Unable to load dynamic library 'swoole.so' (tried: /usr/local/lib/php/extensions/no-debug-non-zts-20210903/swoole.so (/usr/local/lib/php/extensions/no-debug-non-zts-20210903/swoole.so: cannot open shared object file: No such file or directory), /usr/local/lib/php/extensions/no-debug-non-zts-20210903/swoole.so.so (/usr/local/lib/php/extensions/no-debug-non-zts-20210903/swoole.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
    PHP 8.2.0alpha1 (cli) (built: Jun 11 2022 01:48:46) (NTS)
    Copyright (c) The PHP Group
    Zend Engine v4.2.0-dev, Copyright (c) Zend Technologies
       with Zend OPcache v8.2.0alpha1, Copyright (c), by Zend Technologies
    
    rm -f /etc/centminmod/php.d/swoole.ini
    
    fpmrestart
    

    Code (Text):
    --------------------------------------------------------
        Centmin Mod Menu 130.00beta01 centminmod.com    
    --------------------------------------------------------
    1).  Centmin Install
    2).  Add Nginx vhost domain
    3).  NSD setup domain name DNS
    4).  Nginx Upgrade / Downgrade
    5).  PHP Upgrade / Downgrade
    6).  XCache Re-install
    7).  APC Cache Re-install
    8).  XCache Install
    9).  APC Cache Install
    10). Memcached Server Re-install
    11). MariaDB MySQL Upgrade & Management
    12). Zend OpCache Install/Re-install
    13). Install/Reinstall Redis PHP Extension
    14). SELinux disable
    15). Install/Reinstall ImagicK PHP Extension
    16). Change SSHD Port Number
    17). Multi-thread compression: zstd,pigz,pbzip2,lbzip2
    18). Suhosin PHP Extension install
    19). Install FFMPEG and FFMPEG PHP Extension
    20). NSD Install/Re-Install
    21). Data Transfer (TBA)
    22). Add Wordpress Nginx vhost + Cache Plugin
    23). Update Centmin Mod Code Base
    24). Exit
    --------------------------------------------------------
    Enter option [ 1 - 24 ] 5
    --------------------------------------------------------
    y
        ____   _   _  ____       _   _                                _      
       |  _ \ | | | ||  _ \  _  | | | | _ __    __ _  _ __  __ _   __| |  ___
       | |_) || |_| || |_) |(_) | | | || '_ \  / _` || '__|/ _` | / _` | / _ \
       |  __/ |  _  ||  __/  _  | |_| || |_) || (_| || |  | (_| || (_| ||  __/
       |_|    |_| |_||_|    (_)  \___/ | .__/  \__, ||_|   \__,_| \__,_| \___|
                                       |_|     |___/                        
    
    PHP Upgrade/Downgrade - Would you like to continue? [y/n] y
    

    Code (Text):
    ----------------------------------------------------------------
    Install which version of PHP? (i.e. 7.3.33, 7.4.30, 8.0.20, 8.1.7, 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.1 dev builds minus incompatible PHP extensions
    ----------------------------------------------------------------
    
    Current PHP Version: 8.2.0alpha1
    Can Not Determine Latest PHP Version Installable:
    
    Enter PHP Version number you want to upgrade/downgrade to: 8.2.0alpha1
    
    Do you still want to continue? [y/n] y
    
    ----------------------------------------------------------------
    existing php.ini will be backed up at /usr/local/lib/php.ini-oldversion_110622-014653
    ----------------------------------------------------------------
    HTTP/1.1 200 OK
    Downloading PHP 8.2.0alpha1 from https://downloads.php.net/~sergey//
    Download php-8.2.0alpha1.tar.xz ...
    wget -4cnv https://downloads.php.net/~sergey//php-8.2.0alpha1.tar.xz --tries=3
    2022-06-11 01:47:03 URL:https://downloads.php.net/~sergey//php-8.2.0alpha1.tar.xz [11714724/11714724] -> "php-8.2.0alpha1.tar.xz" [1]
    Download done.
    php-8.2.0alpha1.tar.xz valid file.
    
    -----------------------------------------------------------------------------------------
    Detected PHP 8.2 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
    

    End result
    Code (Text):
    php -v
    PHP 8.2.0alpha1 (cli) (built: Jun 11 2022 01:48:46) (NTS)
    Copyright (c) The PHP Group
    Zend Engine v4.2.0-dev, Copyright (c) Zend Technologies
       with Zend OPcache v8.2.0alpha1, Copyright (c), by Zend Technologies


    Code (Text):
    php-config
    Usage: /usr/local/bin/php-config [OPTION]
    Options:
      --prefix            [/usr/local]
      --includes          [-I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib]
      --ldflags           [ -L/opt/openssl/lib -L/usr/local/libgd/2.3.3/lib -L/usr/local/lib64]
      --libs              [-lcrypt  -lc-client  -ltidy -lresolv -lncurses -laspell -lpspell -lrt -lldap -llber -lstdc++ -lcrypt -lpam -lgmp -lbz2 -lutil -lrt -lm -ldl  -lsystemd -lxml2 -lgssapi_krb5 -lkrb5 -lk5crypto -lcom_err -lssl -lcrypto -ldl -lpthread -lsqlite3 -lz -lcurl -lxml2 -lenchant -lgmodule-2.0 -lglib-2.0 -lffi -lssl -lcrypto -ldl -lpthread -lgd -lgssapi_krb5 -lkrb5 -lk5crypto -lcom_err -lssl -lcrypto -ldl -lpthread -licuio -licui18n -licuuc -licudata -lonig -lsqlite3 -ledit -ltinfo -lxml2 -lnetsnmp -lssl -lssl -lcrypto -lm -lxml2 -lsodium -largon2 -lxml2 -lxml2 -lxml2 -lxslt -lxml2 -lexslt -lxslt -lxml2 -lzip -lz -lssl -lcrypto -ldl -lpthread -lcrypt ]
      --extension-dir     [/usr/local/lib/php/extensions/no-debug-non-zts-20210903]
      --include-dir       [/usr/local/include/php]
      --man-dir           [/usr/local/php/man]
      --php-binary        [/usr/local/bin/php]
      --php-sapis         [ cli embed fpm phpdbg cgi]
      --ini-path          [/usr/local/lib]
      --ini-dir           [/etc/centminmod/php.d]
      --configure-options [--enable-fpm --enable-opcache --enable-intl --enable-pcntl --with-mcrypt --with-snmp --enable-embed=shared --with-mhash --with-zlib --with-gettext --enable-exif --with-zip --with-libzip --with-bz2 --enable-soap --enable-sockets --enable-sysvmsg --enable-sysvsem --enable-sysvshm --with-mysql-sock=/var/lib/mysql/mysql.sock --with-curl --enable-gd --with-external-gd --with-xmlrpc --enable-bcmath --enable-calendar --enable-ftp --enable-gd-native-ttf --with-freetype --with-jpeg --with-png-dir=/usr --with-xpm --with-webp --with-t1lib=/usr --enable-shmop --with-pear --enable-mbstring --with-openssl=/opt/openssl --with-mysql=mysqlnd --with-libdir=lib64 --with-mysqli=mysqlnd --enable-pdo --with-pdo-sqlite --with-pdo-mysql=mysqlnd --enable-inline-optimization --with-imap --with-imap-ssl --with-kerberos --with-readline --with-libedit --with-gmp --with-pspell --with-tidy --with-enchant --with-fpm-user=nginx --with-fpm-group=nginx --with-ldap --with-ldap-sasl --with-password-argon2 --with-sodium=/usr/local --with-config-file-scan-dir=/etc/centminmod/php.d --with-fpm-systemd --with-ffi --with-xsl PKG_CONFIG_PATH=/opt/rh/devtoolset-10/root/usr/lib64/pkgconfig:/opt/rh/devtoolset-10/root/usr/lib64/pkgconfig OPENSSL_CFLAGS=-I/opt/openssl/include OPENSSL_LIBS=-L/opt/openssl/lib -lssl -lcrypto -ldl -lpthread GDLIB_CFLAGS=-I/usr/local/libgd/2.3.3/include GDLIB_LIBS=-L/usr/local/libgd/2.3.3/lib -lgd ICU_CFLAGS=-I/usr/include ICU_LIBS=-L/usr/lib64 -licuio -licui18n -licuuc -licudata LIBSODIUM_CFLAGS=-I/usr/local/include LIBSODIUM_LIBS=-L/usr/local/lib64 -lsodium ARGON2_CFLAGS=-I/usr/local/include ARGON2_LIBS=-L/usr/local/lib64 -largon2 LIBZIP_CFLAGS=-I/usr/local/include LIBZIP_LIBS=-L/usr/local/lib64 -lzip]
      --version           [8.2.0alpha1]
      --vernum            [80200]


    Code (Text):
    php -m
    [PHP Modules]
    bcmath
    brotli
    bz2
    calendar
    Core
    ctype
    curl
    date
    dom
    enchant
    event
    exif
    FFI
    fileinfo
    filter
    ftp
    gd
    geoip
    gettext
    gmp
    hash
    iconv
    igbinary
    imagick
    imap
    intl
    json
    ldap
    libxml
    mailparse
    maxminddb
    mbstring
    mcrypt
    mysqli
    mysqlnd
    openssl
    pcntl
    pcre
    PDO
    pdo_mysql
    pdo_sqlite
    Phar
    posix
    pspell
    readline
    redis
    Reflection
    session
    shmop
    SimpleXML
    snmp
    soap
    sockets
    sodium
    SPL
    sqlite3
    standard
    sysvmsg
    sysvsem
    sysvshm
    tidy
    timezonedb
    tokenizer
    xml
    xmlreader
    xmlwriter
    xsl
    Zend OPcache
    zip
    zlib
    
    [Zend Modules]
    Zend OPcache


    Code (Text):
    php -r 'print_r(get_defined_constants());' | grep -i argon
       [PASSWORD_ARGON2I] => argon2i
       [PASSWORD_ARGON2ID] => argon2id
       [PASSWORD_ARGON2_DEFAULT_MEMORY_COST] => 65536
       [PASSWORD_ARGON2_DEFAULT_TIME_COST] => 4
       [PASSWORD_ARGON2_DEFAULT_THREADS] => 1
       [PASSWORD_ARGON2_PROVIDER] => standard
       [SODIUM_CRYPTO_PWHASH_ALG_ARGON2I13] => 1
       [SODIUM_CRYPTO_PWHASH_ALG_ARGON2ID13] => 2
       [SODIUM_CRYPTO_PWHASH_STRPREFIX] => $argon2id$


    Code (Text):
    php --ri openssl
    
    openssl
    
    OpenSSL support => enabled
    OpenSSL Library Version => OpenSSL 1.1.1o  3 May 2022
    OpenSSL Header Version => OpenSSL 1.1.1o  3 May 2022
    Openssl default config => /opt/openssl/openssl.cnf
    
    Directive => Local Value => Master Value
    openssl.cafile => no value => no value
    openssl.capath => no value => no value