After updating to Nextcloud 28 I got error 500 when accessing Nextcloud as well. I saw this in the logs:
[Tue Jan 02 18:41:06.284450 2024] [proxy_fcgi:error] [pid 1721916:tid 140346731693824] [remote 152.117.66.146:56627] AH01071: Got error 'PHP message: PHP Warning: require_once(/var/www/clients/client0/web12/web/lib/versioncheck.php): Failed to open stream: No such file or directory in /var/www/clients/client0/web12/web/ocs/v1.php on line 30; PHP message: PHP Fatal error: Uncaught Error: Failed opening required '/var/www/clients/client0/web12/web/lib/versioncheck.php' (include_path='.:/usr/share/php') in /var/www/clients/client0/web12/web/ocs/v1.php:30\nStack trace:\n#0 /var/www/clients/client0/web12/web/ocs/v2.php(23): require_once()\n#1 {main}\n thrown in /var/www/clients/client0/web12/web/ocs/v1.php on line 30'
[Tue Jan 02 18:41:12.163089 2024] [proxy_fcgi:error] [pid 1721915:tid 140346630981376] [remote ip:60254] AH01071: Got error 'PHP message: PHP Fatal error: Class OCA\\GroupFolders\\Helper\\LazyFolder contains 2 abstract methods and must therefore be declared abstract or implement the remaining methods (OCP\\Files\\Folder::searchBySystemTag, OCP\\Files\\FileInfo::getMetadata) in /var/www/clients/client0/web12/web/apps/groupfolders/lib/Helper/LazyFolder.php on line 32'
[Tue Jan 02 18:41:14.901489 2024] [proxy_fcgi:error] [pid 1721915:tid 140346740086528] [remote ip:60254] AH01071: Got error 'PHP message: PHP Fatal error: Class OCA\\GroupFolders\\Helper\\LazyFolder contains 2 abstract methods and must therefore be declared abstract or implement the remaining methods (OCP\\Files\\Folder::searchBySystemTag, OCP\\Files\\FileInfo::getMetadata) in /var/www/clients/client0/web12/web/apps/groupfolders/lib/Helper/LazyFolder.php on line 32'
[Tue Jan 02 18:41:15.689836 2024] [proxy_fcgi:error] [pid 1721915:tid 140346731693824] [remote ip:60254] AH01071: Got error 'PHP message: PHP Fatal error: Class OCA\\GroupFolders\\Helper\\LazyFolder contains 2 abstract methods and must therefore be declared abstract or implement the remaining methods (OCP\\Files\\Folder::searchBySystemTag, OCP\\Files\\FileInfo::getMetadata) in /var/www/clients/client0/web12/web/apps/groupfolders/lib/Helper/LazyFolder.php on line 32'
I tried updating groupfolders, but the occ command failed:
root@web1:/var/www/nc.example.com/web# sudo -u web12 php8.2 occ app:update groupfolders
Nextcloud or one of the apps require upgrade - only a limited number of commands are available
You may use your browser or the occ upgrade command to do the upgrade
PHP Fatal error: Class OCA\GroupFolders\Helper\LazyFolder contains 2 abstract methods and must therefore be declared abstract or implement the remaining methods (OCP\Files\Folder::searchBySystemTag, OCP\Files\FileInfo::getMetadata) in /var/www/clients/client0/web12/web/apps/groupfolders/lib/Helper/LazyFolder.php on line 32
The solution was to disable the app:
root@web1:/var/www/nc.example.com/web# sudo -u web12 php8.2 occ app:disable groupfolders
Nextcloud or one of the apps require upgrade - only a limited number of commands are available
You may use your browser or the occ upgrade command to do the upgrade
groupfolders 15.3.2 disabled
Then I wanted to update the app, but this was not allowed because there was still a Nextcloud upgrade pending:
root@web1:/var/www/nc.example.com/web# sudo -u web12 php8.2 occ app:update groupfolders
Nextcloud or one of the apps require upgrade - only a limited number of commands are available
You may use your browser or the occ upgrade command to do the upgrade
So I ran the upgrade with sudo -u web12 php8.2 occ upgrade
and after that I could update and enable groupfolders without a problem:
root@web1:/var/www/nc.example.com/web# sudo -u web12 php8.2 occ app:update groupfolders
groupfolders new version available: 16.0.1
groupfolders updated
root@web1:/var/www/nc.example.com/web# sudo -u web12 php8.2 occ app:enable groupfolders
groupfolders 16.0.1 enabled
TL:DR; disable the app, upgrade Nextcloud, update groupfolders, then re-enable the app:
php occ app:disable groupfolders
php occ upgrade
php occ app:update groupfolders
php occ app:enable groupfolders
Please note that all these commands shall be ran as the same user that the web application runs under.
Hope this helps someone!