Internal server error after update from latest 25.x.x to 26.0.0

Support intro

Sorry to hear you’re facing problems :slightly_frowning_face: is for home/non-enterprise users. If you’re running a business, paid support can be accessed via 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:


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


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): 26.0.0
Operating system and version (eg, Ubuntu 20.04): 22.04.2 LTS
Apache or nginx version (eg, Apache 2.4.25): Apache 2.4.52
PHP version (eg, 7.4): 8.1.17 (according to ‘php -v’)

The issue you are facing:
front page of domain gives

"Internal Server Error

The server encountered an internal error and was unable to complete your request.
Please contact the server administrator if this error reappears multiple times, please include the technical details below in your report.
More details can be found in the server log."

In short: NC26 worked for maybe a day after update from NC25 (stable channel). Around the same time I did a standard update of Ubuntu - there may have been an update to php8.2, which I later tried to uninstall. If that is not the culprit here, another hypothesis is my renewal of Let’s encrypt certificate.

Is this the first time you’ve seen this error? (Y/N): Y

Steps to replicate it (not sure):

  1. upgrade from 25.x.x to 26.0.0
  2. renew let’s encrypt certificate
  3. update normally ubuntu system

The output of your Nextcloud log in Admin > Logging:

cannot login to Nextcloud instance

The output of your config.php file in /path/to/nextcloud (make sure you remove any identifiable information!):

$CONFIG = array (
  'instanceid' => '[instanceid]',
  'passwordsalt' => '[passwordsalt]',
  'secret' => '[secret]',
  'trusted_domains' => 
  array (
    0 => '[public domain]',
    1 => '[local ip]',
    2 => '[public ip]',
    3 => '[local ip]',
  'datadirectory' => '/var/www/html/data',
  'dbtype' => 'mysql',
  'version' => '',
  'overwrite.cli.url' => '[domain]',
  'dbname' => 'nextcloud',
  'dbhost' => 'localhost',
  'dbport' => '',
  'dbtableprefix' => 'oc_',
  'mysql.utf8mb4' => true,
  'dbuser' => '[dbuser]',
  'dbpassword' => '[dbpassword]',
  'installed' => true,
  'memcache.local' => '\\OC\\Memcache\\APCu',
  'maintenance' => false,
  'theme' => '',
  'loglevel' => 2,
  'mail_from_address' => '[from]',
  'mail_smtpmode' => 'smtp',
  'mail_sendmailmode' => 'smtp',
  'mail_domain' => '[domain]',
  'mail_smtphost' => '[domain]',
  'mail_smtpauth' => 1,
  'mail_smtpname' => '[username]',
  'mail_smtppassword' => '[password]',
  'mail_smtpsecure' => 'tls',
  'mail_smtpauthtype' => 'LOGIN',
  'mail_smtpport' => '587',
  'app_install_overwrite' => 
  array (
    0 => 'social',
  'updater.secret' => '[long text with different characters]';```

The output of your Apache/nginx/system log in `/var/log/____`:

[Mon Apr 03 00:00:01.621890 2023] [mpm_prefork:notice] [pid 8742] AH00163: Apache/2.4.52 (Ubuntu) OpenSSL/3.0.2 configured – resuming normal operations
[Mon Apr 03 00:00:01.621939 2023] [core:notice] [pid 8742] AH00094: Command line: ‘/usr/sbin/apache2’
[Mon Apr 03 14:29:05.097617 2023] [authz_core:error] [pid 11945] [client] AH01630: client denied by server configuration: /var/www/html/server-status
[Mon Apr 03 14:29:05.953792 2023] [php:error] [pid 35919] [client] script ‘/var/www/html/info.php’ not found or unable to stat
[Mon Apr 03 17:53:07.501869 2023] [php:error] [pid 16975] [client] script ‘/var/www/html/phpinfo.php’ not found or unable to stat
[Mon Apr 03 19:07:00.655704 2023] [mpm_prefork:notice] [pid 8742] AH00170: caught SIGWINCH, shutting down gracefully
[Mon Apr 03 19:07:26.835773 2023] [mpm_prefork:notice] [pid 1088] AH00163: Apache/2.4.52 (Ubuntu) OpenSSL/3.0.2 configured – resuming normal operations
[Mon Apr 03 19:07:26.852357 2023] [core:notice] [pid 1088] AH00094: Command line: ‘/usr/sbin/apache2’
[Mon Apr 03 22:31:28.903640 2023] [mpm_prefork:notice] [pid 1088] AH00170: caught SIGWINCH, shutting down gracefully
[Mon Apr 03 22:31:30.061103 2023] [mpm_prefork:notice] [pid 14911] AH00163: Apache/2.4.52 (Ubuntu) OpenSSL/3.0.2 configured – resuming normal operations
[Mon Apr 03 22:31:30.061214 2023] [core:notice] [pid 14911] AH00094: Command line: ‘/usr/sbin/apache2’


Output errors in nextcloud.log in /var/www/ or as admin user in top right menu, filtering for errors. Use a pastebin service if necessary.

first this snippet, more in the pastebin below:

{“reqId”:“jxoYzFqXhRMP8m6KqIFK”,“level”:3,“time”:“2023-03-29T10:58:59+00:00”,“remoteAddr”:“[ip address]”,“user”:“–”,“app”:“no app in context”,“method”:“GET”,“url”:“/core/ajax/update.php?requesttoken=Jk%2FQevaohe98415L5Z%2B8VN3GiQBk9tztySdQWT0SKmc%3D%3AUhqFNpGQ9Yorlj04n%2B6JGLCX4VcPgb6J%2FhEWNEU5XTE%3D”,“message”:“App "GeoBlocker" cannot be installed because it is not compatible with this version of the server.”,“userAgent”:“Mozilla/5.0 (X11; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/111.0”,“version”:“”,“exception”:{“Exception”:“Exception”,“Message”:“App "GeoBlocker" cannot be installed because it is not compatible with this version of the server.”,“Code”:0,“Trace”:[{“file”:“/var/www/html/lib/private/legacy/OC_App.php”,“line”:451,“function”:“installApp”,“class”:“OC\Installer”,“type”:“->”},{“file”:“/var/www/html/lib/private/Updater.php”,“line”:431,“function”:“enable”,“class”:“OC_App”,“type”:“->”},{“file”:“/var/www/html/lib/private/Updater.php”,“line”:284,“function”:“upgradeAppStoreApps”,“class”:“OC\Updater”,“type”:“->”},{“file”:“/var/www/html/lib/private/Updater.php”,“line”:140,“function”:“doUpgrade”,“class”:“OC\Updater”,“type”:“->”},{“file”:“/var/www/html/core/ajax/update.php”,“line”:185,“function”:“upgrade”,“class”:“OC\Updater”,“type”:“->”}],“File”:“/var/www/html/lib/private/Installer.php”,“Line”:131,“message”:“App "GeoBlocker" cannot be installed because it is not compatible with this version of the server.”,“exception”:{},“CustomMessage”:“App "GeoBlocker" cannot be installed because it is not compatible with this version of the server.”}}

I resolved it; installed the following php modules:

apt-get install php8.1-{bcmath,xml,fpm,mysql,zip,intl,ldap,gd,cli,bz2,curl,mbstring,pgsql,opcache,soap,cgi}

so my best guess is that ubuntu 22.04 did an update from php 8.0 to 8.1 and in the process broke my nc instance. and that a simple change from php 8.0 to 8.1 was not enough until manually installing the above mentioned modules. not totally sure about this, but for now, my best guess.

1 Like

Great that you solved it yourself!

For all of you coming here by the search function:

As you have learned, with a simple update, the entire PHP version has been changed and that behaviour is a trap for the trouble-free operation of a web server. Since you as admin should decide when to switch php version, one should follow the motto “as little as possible, as much as necessary”.
The automatic update from one to the next version is done by so called “dependency-packages” like ‘php’ and other packages with names like php-{module} (without the version String) Those packages can almost all safely be removed, what will give you back the control over your php-version. When you try to deinstall a package, you will see if it is a dependency for one or more php8.1-* modules (like php-common which is allways needed). All other packages that don’t meet any dependencies can and should be removed.
A package as ‘php8.1’ is a so caled “meta-package” and is just as useful as a toothache too.

you installed some not used packages:

It is eather fpm or cgi. I gues you are using fpm
It is eather mysql or pgsql. You are using mysql
Nextcloud does not make use of soap
Do you use the LDAP backend? If not, the ldap module can be removed too

therefore you did not install:
apcu. You are using apcu as memcache, so I guess that it’s already installed, make clear that it is the 8.1 version.
gmp and imagick are used by Nextcloud, check if 8.1 versions are installed.

When you finally switch the version manualy to 8.1 with update-alternatives --all, then you have gained the total control back over your php-verrsions. No update will change the php-version no more and you can even have and handle multiple versions installed, switching from one to the other and back within a couple of seconds.
(There are of course the steps to switch the fpm version in the apache server but I assume you know that.)


Hello everyone, based on few reply founded on the Net, I found that for me the resolution it was disable W2G2 Nextcloud plugin (the one that allows the users to lock files and folders. It works with files and folders owned by the user, shared by another user or inside a group folder)!