Nextcloud hub II error when upgrading to php8

Nextcloud version: 23.0.2
Operating system and version : Ubuntu 20.04
Apache or nginx version (eg, Apache 2.4.25): replace me
PHP version: 7.4

Hello all,

I have updated nextcloud to the latest version and all is well. I noticed that my php version is 7.4 and read that this will be replaced by 8.0 at some point so I thought to update that to 8.0. I have read a few guides including from this site and updated php to 8.0 but then I cannot access the nextcloud web page. It get an unknown error which sends me to talk to the administrator.

So I have been talking to myself lately about how to solve this or if I should just leave it to php7.4 on account of if it ain’t broke don’t fix it.

Should I update to php 8.0? and if I should, what is the proper procedure? For me this php business is a black box and I do not understand how to fix stuff related to it but I try!

I usually helps to look into the logfiles. Perhaps some module missing… There is no urgent need to upgrade your php now, on the long run, you’ll probably have to, or wait and upgrade with the underlying system to the next Ubuntu LTS.

what prompted me to try to update was these error that I get when I try to look at the deleted files folder:

"reqId":"4hQHNLke0se52x5f0dTc","level":3,"time":"2022-02-26T01:05:12+02:00","remoteAddr":"","user":"lucian","app":"PHP","method":"PROPFIND","url":"/remote.php/dav/trashbin/lucian/trash","message":"Allowed memory size of 536870912 bytes exhausted (tried to allocate 101130968 bytes) at /var/www/nextcloud/apps/dav/lib/Connector/Sabre/PropfindCompressionPlugin.php#68","userAgent":"Mozilla/5.0 (X11; Linux x86_64; rv:97.0) Gecko/20100101 Firefox/97.0","version":""}

I also have these error which I have no idea where they are coming from:

{"reqId":"wSgT29TGrz4WVYaoYZdz","level":3,"time":"2022-02-26T00:34:43+02:00","remoteAddr":"","user":"lucian","app":"PHP","method":"GET","url":"/core/preview?fileId=1201438&x=256&y=256&a=true&v="66feaab76699fc26611478b246e3f013"","message":"Module 'igbinary' already loaded at Unknown#0","userAgent":"Mozilla/5.0 (X11; Linux x86_64; rv:97.0) Gecko/20100101 Firefox/97.0","version":""}

Since they were related to some php files and other people had similar problems, I figured that updating to a newer version will help… I am sure these are the famous last words of a sysadmin somewhere! Luckily I did a backup of the VM running the nextcloud instance!

If you have enough memory left, you can give php more than 512 MB. If not, here it is the trashbin that tries to allocate ~100 MB, here it doesn’t show for what the rest is used.

how do I do that specifically? i have checked the php.ini and there is a memory limit line and it is -1. I read that it means it can eat as much as it wants.