PHP8.2 with Nextcloud 25.0.2

Support intro

Sorry to hear you’re facing problems :slightly_frowning_face:

help.nextcloud.com is for home/non-enterprise users. If you’re running a business, paid support can be accessed via portal.nextcloud.com where we can ensure your business keeps running smoothly.

In order to help you as quickly as possible, before clicking Create Topic please provide as much of the below as you can. Feel free to use a pastebin service for logs, otherwise either indent short log examples with four spaces:

example

Or for longer, use three backticks above and below the code snippet:

longer
example
here

Some or all of the below information will be requested if it isn’t supplied; for fastest response please provide as much as you can :heart:

Nextcloud version (eg, 20.0.5): 25.0.2
Operating system and version (eg, Ubuntu 20.04): Debian 11
Apache or nginx version (eg, Apache 2.4.25): Apache/2.4.54
PHP version (eg, 7.4): 8.1

The issue you are facing:
After Update via apt update && apt-upgrade there was an upgrade to php8.2. Then my Nextcloud Webserver crashed with an unspecified error. I found the solution to uninstall all versions of php and reinstall php8.1. It seems that Nextcloud 25.0.2 cannot run with php8.2.

There should be some error reported. Did you check both the webserver and nextcloud logs?

PHP 8.2 support is planned for Nextcloud 26: https://github.com/nextcloud/server/issues/32595#issuecomment-1313279527

1 Like

Support for PHP 8.2 has not been announced
See System requirements

Thank you very much for this information :slightly_smiling_face::+1:

1 Like

It would be “nice” if the upgrade warning also highlighted this. I’ve merrily installed 8.2 to find it doesn’t work:

Fortunately, I’ve just done the upgrade on my test Nextcloud VM so can restore snapshot.

1 Like

I found the solution to uninstall all versions of php and reinstall php8.1

Hello,
unfortunately I am not so fit in Debian. Could you please send me the link to your solution?

Www.google.com… lil’ joke :wink:

https://stackoverflow.com/questions/58045685/uninstall-php-7-in-ubuntu-18-04

^^^ always a good source

Greetings

Whilst Linux is growing on me, things like major upgrades of PHP still fill me with fear and uncertainty. My client is running on Centos 7 so for the record, these are the instructions to upgrade from PHP v7.x to 8.1 on a Centos 7, NGINX, MariaDB system:

Stop services systemctl stop nginx mariadb php-fpm
Install latest repository tools yum -y install https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
Install latest repository tools yum -y install https://rpms.remirepo.net/enterprise/remi-release-7.rpm
Disable older versions of PHP yum-config-manager --disable ‘remi-php*’
Configure to install PHP v8.1 yum-config-manager --enable remi-php81
Install PHP yum -y install php php-mcrypt php-cli php-gd php-curl php-mysql php-ldap php-zip php-fileinfo php-snmp php-mbstring php-pecl-zip php-xmlrpc libxslt php-xml php-fpm
Start services systemctl start nginx mariadb php-fpm

I ran them with sudo -i so don’t need sudo in front. Although that’s not the complete (massive) stack of PHP modules, those not listed seem to sort themselves out. Bit of “with a following wind” kind of upgrade.

I also ran into this problem but i just manually changed php version to 8.1 with this command

sudo update-alternatives --config php

after i picked php 8.1 everything was back to normal… now its just waiting time until nexcloud support 8.2

2 Likes

Thanks for this workaround.
I think I heard Nextcloud 26 should support PHP 8.2 …

Many greetings

This just ******** my config, i spend hours, en then i read this…

This.

Manually reinstall php8.1 (so that it gets flagged as manually installed) and use this and you should be fine with updates in the future.

Thanks a lot.

I am currently running php 7.4 and have a warning that says:

That page lists 8.0, 8.1, and 8.2 as currently supported. If something listed there isn’t compatible maybe additional context or actually supported versions should be listed. I luckily searched before doing the upgrade, but almost jumped straight to 8.2 which is what Nextcloud is appearing to say it supports in the warning message.

@nmbgeek
Which operating system and version do you use? It is no problem to use PHP 7.4. If you use e.g. Debian Bullseye (PHP 7.4) you can first upgrade in a few month to Debian Bookworm (PHP 8.1) and then upgrade to e.g. Nextcloud 26.

Alternatively, you can of course include a third-party source with PHP 8.0 or better PHP 8.1 and upgrade PHP for your Nextcloud already now.

I don’t do that. I’m much too lazy for that.

PHP 8.2 is not supported for Nextcloud25.

Hi. The keywords are: …as soon as your distribution supports it… Thats the point.
I ran into an automatic upgrade from php 8.1 to 8.2, which killed my webgui.
So I fixed the version to php8.1, as long as the version is not discontinued, it will stay that way. Only then I will upgrade.
I don’t know why and I wonder how I got NC 25 (as I had configured only the stable-channel-updates), but from the beginning it ran very smoothly and stable, at the moment on an old, but reliable running (and running and running…) computer. The only problem was my linux distribution, which decided to upgrade php…

So be aware for the next announcements. Afaik, NC 26 should support php8.2.

Many greetings

Well because, Nextcloud 25 was officially released as “stable”. I won’t comment on Nextcloud’s “relesae often and release early” strategy, there are already enough discussions on this topic in the forums and it’s offtopic in this thread anyways. :wink:

I run Nextcloud 25 on Debian server. I made some system administration mistakes:
I did not keep the PHP8.1 deb packages.
I failed to disable the PHP update.
Fortunately, I was able to download
PHP 8.1.14 (cli) (built: Jan 13 2023) packages
Manual installation and modification of the php config.
Everything works again.

Maybe not so useful info, but running the Nextclod VM you can’t upgrade to an unsupported version. It will stop you before it happens. :slight_smile: