Hi everyone, so i need to upgrade one of my servers that is in production hosting a website/forum.
I need to upgrade php7 to php8, im only using the official repos from opensuse Leap 15.4.
doing a zypper se php i see that php8 it’s available but I want to know what it’s the must practical way to do the upgrade.
the end goal here is to do the upgrade of php as seamless as possible since we want to keep the server online as much as possible and avoid possible incompatibilities with apache2
i+ | apache2-mod_php7 | PHP7 module for the Apache 2.x webserver | package
i+ | php7 | Interpreter for the PHP scripting language version 7 | package
i+ | php7-bz2 | bzip2 codec support for PHP | package
i | php7-cli | Interpreter for the PHP scripting language version 7 | package
i+ | php7-ctype | Character class extension for PHP | package
i+ | php7-curl | libcurl integration for PHP | package
i+ | php7-dom | Document Object Model extension for PHP | package
i+ | php7-exif | EXIF metadata extensions for PHP | package
i+ | php7-ftp | FTP protocol support for PHP | package
i+ | php7-gd | GD Graphics Library extension for PHP | package
i+ | php7-gettext | Native language support for PHP | package
i+ | php7-iconv | Character set conversion functions for PHP | package
i+ | php7-json | JSON (de)serializer functions for PHP | package
i+ | php7-mbstring | Multibyte string functions for PHP | package
i+ | php7-mysql | MySQL database client for PHP | package
i+ | php7-openssl | OpenSSL integration for PHP | package
i+ | php7-pdo | PHP Data Objects extension for PHP | package
i+ | php7-phar | PHP Archive extension for PHP | package
i+ | php7-sqlite | SQLite database client for PHP | package
i+ | php7-tokenizer | Extension module to access Zend Engine's PHP tokenizer | package
i+ | php7-xmlreader | Streaming XML reader extension for PHP | package
i+ | php7-xmlwriter | Streaming-based XML writer extension for PHP | package
i+ | php7-zip | ZIP archive support for PHP | package
i+ | php7-zlib | Zlib compression support for PHP | package
--+-----------------------------+---------------------------------------------------------------------------------------------+---------+-----------+--------
1 | OSS | OSS | Yes | (r ) Yes | No
2 | non-oss | non-oss | Yes | (r ) Yes | No
3 | packman | packman | Yes | (r ) Yes | Yes
4 | repo-backports-debug-update | Update repository with updates for openSUSE Leap debuginfo packages from openSUSE Backports | No | ---- | ----
5 | repo-backports-update | Update repository of openSUSE Backports | Yes | (r ) Yes | Yes
6 | repo-sle-debug-update | Update repository with debuginfo for updates from SUSE Linux Enterprise 15 | No | ---- | ----
7 | repo-sle-update | Update repository with updates from SUSE Linux Enterprise 15 | Yes | (r ) Yes | Yes
8 | updt-non-oss | updt-non-oss | Yes | (r ) Yes | No
I won’t comment on the PHP version issue, but please when you post output (copy/paste from a terminal emulator) then include two more lines in your copy sweep. That with the prompt and the command before the out put, and the new prompt after the output. Then people know what you did, what you working directory was and which user did it and that it is complete and no snippet.
And about your last listing, when you want to inform others with the list of repositories the system uses, then you failed to do so, because the URLs, that tell us which repos they are, are missing, So better
If you migrate a production server then the most important thing to do before you move from php7 to php8 is to make sure that all your current php code will execute correctly under php8. Once you have done that you can install php8 on your server.
I moved my openSUSE Tumbleweed installation from php7 to php8 some months ago. Here is how I proceeded:
take a list of all currently installed php7packages
install php8 (this should remove php7)
install all php8 modules needed (see list of php7 modules)
make sure apache2-mod_php8 is installed
check (and if necessary adjust) /etc/sysconfig/apache2