Internal error after update, no log

Nextcloud version (eg, 20.0.5): 20.0.14
Operating system and version (eg, Ubuntu 20.04): Debian 11
Apache or nginx version (eg, Apache 2.4.25): nginx 1.1.18
PHP version (eg, 7.4): 7.3 and 7.4

The issue you are facing: I have a very old server (I’m planning to completely overhaul it but I need it to hold on for a few more months as I don’t have any time to do it right now) running Nextcloud 20.0.14 with nginx 1.1.18.

Everything was working well under Debian 10, I just updated it to Debain 11 and then I encountered the “internal error” page which directed me to consult the log file.
The problem is the log file is empty, I tried changing the log level parameter in config.php to no avail.

I realized that going to Debian 11 removed php7.3, that I was using, even though the 7.4 replacement had the same modules installed and the socket was the same for nginx.

I tried to re-install all the 7.3 modules (using the sury repo) and expected everything to go back to normal as my old config files were all still there, but I still get the internal error page.

That particular server had been running for seven years (I used the command line updater several times without any problem). But without any log I’m a bit at a loss and would be thankful for any kind of help.

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

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

<?php
$CONFIG = array (
  'instanceid' => 'REDACTED',
  'passwordsalt' => 'REDACTED',
  'secret' => 'REDACTED',
  'trusted_domains' => 
  array (
    0 => 'REDACTED.org',
  ),
  'memcache.locking' => '\\OC\\Memcache\\Redis',
  'memcache.local' => '\\OC\\Memcache\\Redis',
  'redis' => 
  array (
    'host' => '127.0.0.1',
    'port' => 6379,
    'dbindex' => 0,
    'password' => 'secret',
    'timeout' => 1.5,
  ),
  'datadirectory' => '/mnt/LCARS/nextcloud-data',
  'overwrite.cli.url' => 'https://cloud.spacedock.duckdns.org',
  'dbtype' => 'pgsql',
  'version' => '20.0.4.0',
  'dbname' => 'nextcloud',
  'dbhost' => 'localhost',
  'dbport' => '',
  'dbtableprefix' => 'oc_',
  'dbuser' => 'www-data',
  'dbpassword' => '',
  'installed' => true,
  'mail_from_address' => 'ykonoclast',
  'mail_smtpmode' => 'php',
  'mail_smtpauthtype' => 'LOGIN',
  'mail_domain' => 'protonmail.com',
  'updater.secret' => '$2y$10$/LLxZ7pHoEh0/3NhgdaWFepfVNpqL/Q.KEpR/vi.92./ve0zUo.HS',
  'maintenance' => false,
  'loglevel' => 2,
);

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

If using php7.4

2024/02/21 10:38:29 [error] 2993#2993: *49 FastCGI sent in stderr: "PHP message: PHP Fatal error:  Uncaught Error: Class 'OCA\DAV\Connector\Sabre\ExceptionLoggerPlugin' not found in /var/www/spacedock/nextcloud/remote.php:61
Stack trace:
#0 /var/www/spacedock/nextcloud/remote.php(169): handleException()
#1 {main}
  thrown in /var/www/spacedock/nextcloud/remote.php on line 61" while reading response header from upstream, client: 192.168.1.254, server: cloud.spacedock.duckdns.org, request: "PROPFIND /remote.php/dav/files/ykonoclast/ HTTP/1.1", upstream: "fastcgi://unix:/run/php/php7.4-fpm.sock:", host: "cloud.spacedock.duckdns.org"

And nothing if using php7.3

I am not particularly technical, I set up this server seven years ago and am actually a bit rusted on exactly how I did it so I would be grateful for any kind of help.

First change back to the php version from Debian 11 (PHP 7.4). Please check all other php stuff is uninstalled:
dpkg -l |grep -i php

Execute on command line. Maybe you get further informations, maybe not:
sudo -u www-data php /path/to/nextcloud/index.php

Maybe there is a PHP setting problem. Read this installation guide. Mabe you find some facts of your problem e.g. missing php packages or missing configurations.

Do I misunderstand that?

The socket for 7.3 is (was):

  • /run/php/php7.3-fpm.sock

while the socket for 7.4 is

  • /run/php/php7.4-fpm.sock

Did you adapt the "/etc/nginx/sites-available/nextcloud" to listen to the new socket accordingly?


ernolf

Here is my dpkg -l |grep -i php :

ii  php-bz2                              2:8.3+94+0~20240205.51+debian11~1.gbp6faa2e                                all          bzip2 module for PHP [default]
ii  php-cgi                              2:8.3+94+0~20240205.51+debian11~1.gbp6faa2e                                all          server-side, HTML-embedded scripting language (CGI binary) (default)
ii  php-cli                              2:8.3+94+0~20240205.51+debian11~1.gbp6faa2e                                all          command-line interpreter for the PHP scripting language (default)
ii  php-common                           2:94+0~20240205.51+debian11~1.gbp6faa2e                                    all          Common files for PHP packages
ii  php-curl                             2:8.3+94+0~20240205.51+debian11~1.gbp6faa2e                                all          CURL module for PHP [default]
ii  php-fpm                              2:8.3+94+0~20240205.51+debian11~1.gbp6faa2e                                all          server-side, HTML-embedded scripting language (FPM-CGI binary) (default)
ii  php-gd                               2:8.3+94+0~20240205.51+debian11~1.gbp6faa2e                                all          GD module for PHP [default]
ii  php-igbinary                         3.2.15-1+0~20231202.49+debian11~1.gbpe9ffe8                                armhf        igbinary PHP serializer
ii  php-imagick                          3.7.0-4+0~20231125.43+debian11~1.gbpbf7e27                                 armhf        Provides a wrapper to the ImageMagick library
ii  php-imap                             2:8.3+94+0~20240205.51+debian11~1.gbp6faa2e                                all          IMAP module for PHP [default]
ii  php-intl                             2:8.3+94+0~20240205.51+debian11~1.gbp6faa2e                                all          Internationalisation module for PHP [default]
ii  php-json                             2:8.3+94+0~20240205.51+debian11~1.gbp6faa2e                                all          JSON module for PHP [default]
ii  php-mbstring                         2:8.3+94+0~20240205.51+debian11~1.gbp6faa2e                                all          MBSTRING module for PHP [default]
ii  php-pear                             1:1.10.13+submodules+notgz+2022032202-2+0~20230612.39+debian11~1.gbpfd4c1d all          PEAR Base System
ii  php-pgsql                            2:8.3+94+0~20240205.51+debian11~1.gbp6faa2e                                all          PostgreSQL module for PHP [default]
ii  php-redis                            6.0.2-1+0~20231128.56+debian11~1.gbp9f3071                                 armhf        PHP extension for interfacing with Redis
ii  php-xml                              2:8.3+94+0~20240205.51+debian11~1.gbp6faa2e                                all          DOM, SimpleXML, WDDX, XML, and XSL module for PHP [default]
ii  php-zip                              2:8.3+94+0~20240205.51+debian11~1.gbp6faa2e                                all          Zip module for PHP [default]
rc  php7.0-bz2                           7.0.33-0+deb9u10                                                           armhf        bzip2 module for PHP
rc  php7.0-cli                           7.0.33-0+deb9u10                                                           armhf        command-line interpreter for the PHP scripting language
rc  php7.0-common                        7.0.33-0+deb9u10                                                           armhf        documentation, examples and common module for PHP
rc  php7.0-curl                          7.0.33-0+deb9u10                                                           armhf        CURL module for PHP
rc  php7.0-fpm                           7.0.33-0+deb9u10                                                           armhf        server-side, HTML-embedded scripting language (FPM-CGI binary)
rc  php7.0-gd                            7.0.33-0+deb9u10                                                           armhf        GD module for PHP
rc  php7.0-imap                          7.0.33-0+deb9u10                                                           armhf        IMAP module for PHP
rc  php7.0-intl                          7.0.33-0+deb9u10                                                           armhf        Internationalisation module for PHP
rc  php7.0-json                          7.0.33-0+deb9u10                                                           armhf        JSON module for PHP
rc  php7.0-mbstring                      7.0.33-0+deb9u10                                                           armhf        MBSTRING module for PHP
rc  php7.0-mcrypt                        7.0.33-0+deb9u10                                                           armhf        libmcrypt module for PHP
rc  php7.0-opcache                       7.0.33-0+deb9u10                                                           armhf        Zend OpCache module for PHP
rc  php7.0-pgsql                         7.0.33-0+deb9u10                                                           armhf        PostgreSQL module for PHP
rc  php7.0-phpdbg                        7.0.33-0+deb9u10                                                           armhf        server-side, HTML-embedded scripting language (PHPDBG binary)
rc  php7.0-readline                      7.0.33-0+deb9u10                                                           armhf        readline module for PHP
rc  php7.0-xml                           7.0.33-0+deb9u10                                                           armhf        DOM, SimpleXML, WDDX, XML, and XSL module for PHP
rc  php7.0-zip                           7.0.33-0+deb9u10                                                           armhf        Zip module for PHP
rc  php7.3-bcmath                        7.3.31-1~deb10u1                                                           armhf        Bcmath module for PHP
ii  php7.3-bz2                           7.3.33-14+0~20230902.114+debian11~1.gbp764b27                              armhf        bzip2 module for PHP
ii  php7.3-cgi                           7.3.33-14+0~20230902.114+debian11~1.gbp764b27                              armhf        server-side, HTML-embedded scripting language (CGI binary)
ii  php7.3-cli                           7.3.33-14+0~20230902.114+debian11~1.gbp764b27                              armhf        command-line interpreter for the PHP scripting language
ii  php7.3-common                        7.3.33-14+0~20230902.114+debian11~1.gbp764b27                              armhf        documentation, examples and common module for PHP
ii  php7.3-curl                          7.3.33-14+0~20230902.114+debian11~1.gbp764b27                              armhf        CURL module for PHP
rc  php7.3-dba                           7.3.31-1~deb10u1                                                           armhf        DBA module for PHP
rc  php7.3-enchant                       7.3.31-1~deb10u1                                                           armhf        Enchant module for PHP
ii  php7.3-fpm                           7.3.33-14+0~20230902.114+debian11~1.gbp764b27                              armhf        server-side, HTML-embedded scripting language (FPM-CGI binary)
ii  php7.3-gd                            7.3.33-14+0~20230902.114+debian11~1.gbp764b27                              armhf        GD module for PHP
rc  php7.3-gmp                           7.3.31-1~deb10u1                                                           armhf        GMP module for PHP
ii  php7.3-igbinary                      3.2.15-1+0~20231202.49+debian11~1.gbpe9ffe8                                armhf        igbinary PHP serializer
ii  php7.3-imagick                       3.7.0-4+0~20231125.43+debian11~1.gbpbf7e27                                 armhf        Provides a wrapper to the ImageMagick library
ii  php7.3-imap                          7.3.33-14+0~20230902.114+debian11~1.gbp764b27                              armhf        IMAP module for PHP
rc  php7.3-interbase                     7.3.31-1~deb10u1                                                           armhf        Interbase module for PHP
ii  php7.3-intl                          7.3.33-14+0~20230902.114+debian11~1.gbp764b27                              armhf        Internationalisation module for PHP
ii  php7.3-json                          7.3.33-14+0~20230902.114+debian11~1.gbp764b27                              armhf        JSON module for PHP
rc  php7.3-ldap                          7.3.31-1~deb10u1                                                           armhf        LDAP module for PHP
ii  php7.3-mbstring                      7.3.33-14+0~20230902.114+debian11~1.gbp764b27                              armhf        MBSTRING module for PHP
rc  php7.3-mysql                         7.3.31-1~deb10u1                                                           armhf        MySQL module for PHP
rc  php7.3-odbc                          7.3.31-1~deb10u1                                                           armhf        ODBC module for PHP
ii  php7.3-opcache                       7.3.33-14+0~20230902.114+debian11~1.gbp764b27                              armhf        Zend OpCache module for PHP
ii  php7.3-pgsql                         7.3.33-14+0~20230902.114+debian11~1.gbp764b27                              armhf        PostgreSQL module for PHP
rc  php7.3-phpdbg                        7.3.31-1~deb10u1                                                           armhf        server-side, HTML-embedded scripting language (PHPDBG binary)
rc  php7.3-pspell                        7.3.31-1~deb10u1                                                           armhf        pspell module for PHP
ii  php7.3-readline                      7.3.33-14+0~20230902.114+debian11~1.gbp764b27                              armhf        readline module for PHP
rc  php7.3-recode                        7.3.31-1~deb10u1                                                           armhf        recode module for PHP
ii  php7.3-redis                         6.0.2-1+0~20231128.56+debian11~1.gbp9f3071                                 armhf        PHP extension for interfacing with Redis
rc  php7.3-snmp                          7.3.31-1~deb10u1                                                           armhf        SNMP module for PHP
rc  php7.3-soap                          7.3.31-1~deb10u1                                                           armhf        SOAP module for PHP
rc  php7.3-sqlite3                       7.3.31-1~deb10u1                                                           armhf        SQLite3 module for PHP
rc  php7.3-sybase                        7.3.31-1~deb10u1                                                           armhf        Sybase module for PHP
rc  php7.3-tidy                          7.3.31-1~deb10u1                                                           armhf        tidy module for PHP
ii  php7.3-xml                           7.3.33-14+0~20230902.114+debian11~1.gbp764b27                              armhf        DOM, SimpleXML, WDDX, XML, and XSL module for PHP
rc  php7.3-xmlrpc                        7.3.31-1~deb10u1                                                           armhf        XMLRPC-EPI module for PHP
ii  php7.3-zip                           7.3.33-14+0~20230902.114+debian11~1.gbp764b27                              armhf        Zip module for PHP
ii  php7.4-bz2                           1:7.4.33-8+0~20230904.88+debian11~1.gbp87c414                              armhf        bzip2 module for PHP
ii  php7.4-cgi                           1:7.4.33-8+0~20230904.88+debian11~1.gbp87c414                              armhf        server-side, HTML-embedded scripting language (CGI binary)
ii  php7.4-cli                           1:7.4.33-8+0~20230904.88+debian11~1.gbp87c414                              armhf        command-line interpreter for the PHP scripting language
ii  php7.4-common                        1:7.4.33-8+0~20230904.88+debian11~1.gbp87c414                              armhf        documentation, examples and common module for PHP
ii  php7.4-curl                          1:7.4.33-8+0~20230904.88+debian11~1.gbp87c414                              armhf        CURL module for PHP
ii  php7.4-fpm                           1:7.4.33-8+0~20230904.88+debian11~1.gbp87c414                              armhf        server-side, HTML-embedded scripting language (FPM-CGI binary)
ii  php7.4-gd                            1:7.4.33-8+0~20230904.88+debian11~1.gbp87c414                              armhf        GD module for PHP
ii  php7.4-igbinary                      3.2.15-1+0~20231202.49+debian11~1.gbpe9ffe8                                armhf        igbinary PHP serializer
ii  php7.4-imagick                       3.7.0-4+0~20231125.43+debian11~1.gbpbf7e27                                 armhf        Provides a wrapper to the ImageMagick library
ii  php7.4-imap                          1:7.4.33-8+0~20230904.88+debian11~1.gbp87c414                              armhf        IMAP module for PHP
ii  php7.4-intl                          1:7.4.33-8+0~20230904.88+debian11~1.gbp87c414                              armhf        Internationalisation module for PHP
ii  php7.4-json                          1:7.4.33-8+0~20230904.88+debian11~1.gbp87c414                              armhf        JSON module for PHP
ii  php7.4-mbstring                      1:7.4.33-8+0~20230904.88+debian11~1.gbp87c414                              armhf        MBSTRING module for PHP
ii  php7.4-opcache                       1:7.4.33-8+0~20230904.88+debian11~1.gbp87c414                              armhf        Zend OpCache module for PHP
ii  php7.4-pgsql                         1:7.4.33-8+0~20230904.88+debian11~1.gbp87c414                              armhf        PostgreSQL module for PHP
ii  php7.4-phpdbg                        1:7.4.33-8+0~20230904.88+debian11~1.gbp87c414                              armhf        server-side, HTML-embedded scripting language (PHPDBG binary)
ii  php7.4-readline                      1:7.4.33-8+0~20230904.88+debian11~1.gbp87c414                              armhf        readline module for PHP
ii  php7.4-redis                         6.0.2-1+0~20231128.56+debian11~1.gbp9f3071                                 armhf        PHP extension for interfacing with Redis
ii  php7.4-xml                           1:7.4.33-8+0~20230904.88+debian11~1.gbp87c414                              armhf        DOM, SimpleXML, XML, and XSL module for PHP
ii  php7.4-zip                           1:7.4.33-8+0~20230904.88+debian11~1.gbp87c414                              armhf        Zip module for PHP
ii  php8.3-bz2                           8.3.3-1+0~20240216.17+debian11~1.gbp87e37b                                 armhf        bzip2 module for PHP
ii  php8.3-cgi                           8.3.3-1+0~20240216.17+debian11~1.gbp87e37b                                 armhf        server-side, HTML-embedded scripting language (CGI binary)
ii  php8.3-cli                           8.3.3-1+0~20240216.17+debian11~1.gbp87e37b                                 armhf        command-line interpreter for the PHP scripting language
ii  php8.3-common                        8.3.3-1+0~20240216.17+debian11~1.gbp87e37b                                 armhf        documentation, examples and common module for PHP
ii  php8.3-curl                          8.3.3-1+0~20240216.17+debian11~1.gbp87e37b                                 armhf        CURL module for PHP
ii  php8.3-fpm                           8.3.3-1+0~20240216.17+debian11~1.gbp87e37b                                 armhf        server-side, HTML-embedded scripting language (FPM-CGI binary)
ii  php8.3-gd                            8.3.3-1+0~20240216.17+debian11~1.gbp87e37b                                 armhf        GD module for PHP
ii  php8.3-igbinary                      3.2.15-1+0~20231202.49+debian11~1.gbpe9ffe8                                armhf        igbinary PHP serializer
ii  php8.3-imagick                       3.7.0-4+0~20231125.43+debian11~1.gbpbf7e27                                 armhf        Provides a wrapper to the ImageMagick library
ii  php8.3-imap                          8.3.3-1+0~20240216.17+debian11~1.gbp87e37b                                 armhf        IMAP module for PHP
ii  php8.3-intl                          8.3.3-1+0~20240216.17+debian11~1.gbp87e37b                                 armhf        Internationalisation module for PHP
ii  php8.3-mbstring                      8.3.3-1+0~20240216.17+debian11~1.gbp87e37b                                 armhf        MBSTRING module for PHP
ii  php8.3-opcache                       8.3.3-1+0~20240216.17+debian11~1.gbp87e37b                                 armhf        Zend OpCache module for PHP
ii  php8.3-pgsql                         8.3.3-1+0~20240216.17+debian11~1.gbp87e37b                                 armhf        PostgreSQL module for PHP
ii  php8.3-phpdbg                        8.3.3-1+0~20240216.17+debian11~1.gbp87e37b                                 armhf        server-side, HTML-embedded scripting language (PHPDBG binary)
ii  php8.3-readline                      8.3.3-1+0~20240216.17+debian11~1.gbp87e37b                                 armhf        readline module for PHP
ii  php8.3-redis                         6.0.2-1+0~20231128.56+debian11~1.gbp9f3071                                 armhf        PHP extension for interfacing with Redis
ii  php8.3-xml                           8.3.3-1+0~20240216.17+debian11~1.gbp87e37b                                 armhf        DOM, SimpleXML, XML, and XSL module for PHP
ii  php8.3-zip                           8.3.3-1+0~20240216.17+debian11~1.gbp87e37b                                 armhf        Zip module for PHP

As for sudo -u www-data php /path/to/nextcloud/index.php this is getting interesting as I get :

This version of Nextcloud is not compatible with > PHP 7.4.<br/>You are currently running 8.3.3-1+0~20240216.17+debian11~1.gbp87e37b.

Why would it say I’m running 8.3.3?

For, so as to answer Ernolf : I was using the /etc/alternatives socket, which was a symlink to /run/php/php7.3-fpm.sock and got updated to /run/php/php7.4-fpm.sock with the update.

Naturally I then tested with both the exact absolute paths. I currently have /run/php/php7.4-fpm.sock in the nginx conf, as devnull suggested. No idea why 8.3.3 is used.

Thats very simple, because you called it from the commandline which relies on the cli SAPI of php. That one uses php 8.3:

readlink -f $(which php)

You should realy remove all not used php packages:

sudo apt-get purge *php7.0* *php8.3*

then you should get rid of all unnecessary dependency packages.

You can install and run the php-updater script, it will give you comprehensive information about which package is a dependency package and which one is not.
It comes with an extensive help guide. Read it carefully, then - I hope - everything will be clear to you.


ernolf

While you’re at it, you should delete all “rc” packages. Only the configuration is still available here. This at least increases the overview. However, you should only do this if you really no longer need the configurations for these orphaned packages.

apt-get remove --purge $(dpkg -l | awk '/^rc/{print $2}')

cli vs. web:
Yes there is a difference and my command php index.php can show the error or not.

Ok, so I re-executed php index.php with the real php7.4 command, here is the result :

<!DOCTYPE html>
<html class="ng-csp" data-placeholder-focus="false" lang="en" data-locale="en" >
	<head
 data-requesttoken="">
		<meta charset="utf-8">
		<title>
		Nextcloud		</title>
		<meta http-equiv="X-UA-Compatible" content="IE=edge">
		<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0">
				<meta name="apple-itunes-app" content="app-id=1125420102">
				<meta name="theme-color" content="#0082c9">
		<link rel="icon" href="/core/img/favicon.ico">
		<link rel="apple-touch-icon" href="/core/img/favicon-touch.png">
		<link rel="mask-icon" sizes="any" href="/core/img/favicon-mask.svg" color="#0082c9">
		<link rel="manifest" href="/core/img/manifest.json">
		<link rel="stylesheet" href="/core/css/guest.css?v=9242ae8e-6">
		<script nonce="dURyZ0t0SHBvKzJjZHBIYjVQN2Fvek1YU3dJbkZnMXVaNUxtekpQVXM5Yz06NjEzUVQ3S0M5NVhmTk9LWDBKdXF6MFloUGxaQmYxdzlNY3ZmaTl5QzVwaz0=" defer src="/core/js/dist/main.js?v=9242ae8e-6"></script>
			</head>
	<body id="body-login">
		<noscript>
	<div id="nojavascript">
		<div>
			This application requires JavaScript for correct operation. Please <a href="https://www.enable-javascript.com/" target="_blank" rel="noreferrer noopener">enable JavaScript</a> and reload the page.		</div>
	</div>
</noscript>
				<div class="wrapper">
			<div class="v-align">
									<header role="banner">
						<div id="header">
							<div class="logo">
								<h1 class="hidden-visually">
									Nextcloud								</h1>
															</div>
						</div>
					</header>
								<main>
					<div class="error error-wide">
	<h2>Internal Server Error</h2>
	<p>The server was unable to complete your request.</p>
	<p>If this happens again, please send the technical details below to the server administrator.</p>
	<p>More details can be found in the server log.</p>

	<h3>Technical details</h3>
	<ul>
		<li>Remote Address: </li>
		<li>Request ID: 4dyAByUN99JdUh7pUKjE</li>
			</ul>

	</div>
				</main>
			</div>
		</div>
		<footer role="contentinfo">
			<p class="info">
				<a href="https://nextcloud.com" target="_blank" rel="noreferrer noopener">Nextcloud</a> – a safe home for all your data			</p>
		</footer>
	</body>
</html>

Sorry the cli way does not help. Please read this installation guide and check if all packages are installed and maybe check configurations for nginx and php.

Then check your logs in /var/log/, logs for nginx and Nextcloud log /path/to/nextcloud/data/nextcloud.log and post more infos.

The requirement for Nextcloud 20 seems ok.

Do you really want to upgrade 8 times to Nextcloud 28? Maybe you can install Nextcloud 28 better. You can include your old files in your new Nextcloud. But you will lose all other structures.

The plan is to completely rebuild this server on a new machine and a much updated software base (new nginx, fresh nextcloud install etc.) in a few months.

I just need this one to hold on just a bit longer (and I sincerely regret making this Debian update now…).

Still nothing in nextcloud log. Nginx access log has nothing either, error log (with php 7.4) is still the same :

2024/02/21 15:47:16 [error] 31694#31694: *5 FastCGI sent in stderr: "PHP message: PHP Fatal error:  Uncaught Error: Class 'OCA\DAV\Connector\Sabre\ExceptionLoggerPlugin' not found in /var/www/spacedock/nextcloud/remote.php:61
Stack trace:
#0 /var/www/spacedock/nextcloud/remote.php(169): handleException()
#1 {main}
  thrown in /var/www/spacedock/nextcloud/remote.php on line 61" while reading response header from upstream, client: 192.168.1.254, server: cloud.spacedock.duckdns.org, request: "PROPFIND /remote.php/dav/files/ykonoclast/ HTTP/1.1", upstream: "fastcgi://unix:/run/php/php7.4-fpm.sock:", host: "cloud.spacedock.duckdns.org"

I checked packages installation, I didn’t have libmagickcore-dev, I installed it but the situation is unchanged.

I didn’t modify my nginx config (appart from the php socket), it was working this very morning when I did my last sync before starting the Debian update. I hadn’t realize this would break Nextcloud so thoroughly (I did it before, I just had to change the socket, make sure modules were installed and update php config and I was good to go).

What is the echo of

sudo systemctl status *fpm*

ernolf

What is the echo of

sudo systemctl status *fpm*
* php7.3-fpm.service - The PHP 7.3 FastCGI Process Manager
     Loaded: loaded (/lib/systemd/system/php7.3-fpm.service; enabled; vendor pr>
     Active: active (running) since Wed 2024-02-21 11:35:39 CET; 1 day 8h ago
       Docs: man:php-fpm7.3(8)
   Main PID: 2618 (php-fpm7.3)
     Status: "Processes active: 0, idle: 3, Requests: 1301, slow: 0, Traffic: 0>
      Tasks: 4 (limit: 1618)
     Memory: 50.8M
     CGroup: /system.slice/php7.3-fpm.service
             |- 2618 php-fpm: master process (/etc/php/7.3/fpm/php-fpm.conf)
             |- 2956 php-fpm: pool www
             |- 2973 php-fpm: pool www
             `-12637 php-fpm: pool www

Feb 21 11:35:37 vero systemd[1]: Starting The PHP 7.3 FastCGI Process Manager...
Feb 21 11:35:39 vero systemd[1]: Started The PHP 7.3 FastCGI Process Manager.

* php7.4-fpm.service - The PHP 7.4 FastCGI Process Manager
     Loaded: loaded (/lib/systemd/system/php7.4-fpm.service; enabled; vendor pr>
     Active: active (running) since Wed 2024-02-21 15:46:41 CET; 1 day 3h ago
       Docs: man:php-fpm7.4(8)
   Main PID: 31660 (php-fpm7.4)
     Status: "Processes active: 0, idle: 2, Requests: 98, slow: 0, Traffic: 0re>
lines 1-23...skipping...
* php7.3-fpm.service - The PHP 7.3 FastCGI Process Manager
     Loaded: loaded (/lib/systemd/system/php7.3-fpm.service; enabled; vendor preset: enabled)
     Active: active (running) since Wed 2024-02-21 11:35:39 CET; 1 day 8h ago
       Docs: man:php-fpm7.3(8)
   Main PID: 2618 (php-fpm7.3)
     Status: "Processes active: 0, idle: 3, Requests: 1301, slow: 0, Traffic: 0req/sec"
      Tasks: 4 (limit: 1618)
     Memory: 50.8M
     CGroup: /system.slice/php7.3-fpm.service
             |- 2618 php-fpm: master process (/etc/php/7.3/fpm/php-fpm.conf)
             |- 2956 php-fpm: pool www
             |- 2973 php-fpm: pool www
             `-12637 php-fpm: pool www

Feb 21 11:35:37 vero systemd[1]: Starting The PHP 7.3 FastCGI Process Manager...
Feb 21 11:35:39 vero systemd[1]: Started The PHP 7.3 FastCGI Process Manager.

* php7.4-fpm.service - The PHP 7.4 FastCGI Process Manager
     Loaded: loaded (/lib/systemd/system/php7.4-fpm.service; enabled; vendor preset: enabled)
     Active: active (running) since Wed 2024-02-21 15:46:41 CET; 1 day 3h ago
       Docs: man:php-fpm7.4(8)
   Main PID: 31660 (php-fpm7.4)
     Status: "Processes active: 0, idle: 2, Requests: 98, slow: 0, Traffic: 0req/sec"
      Tasks: 3 (limit: 1618)
     Memory: 20.6M
     CGroup: /system.slice/php7.4-fpm.service
             |-31660 php-fpm: master process (/etc/php/7.4/fpm/php-fpm.conf)
             |-31662 php-fpm: pool www
             `-31663 php-fpm: pool www

Feb 21 15:46:41 vero systemd[1]: Starting The PHP 7.4 FastCGI Process Manager...
Feb 21 15:46:41 vero systemd[1]: Started The PHP 7.4 FastCGI Process Manager.

* php8.3-fpm.service - The PHP 8.3 FastCGI Process Manager
     Loaded: loaded (/lib/systemd/system/php8.3-fpm.service; enabled; vendor preset: enabled)
     Active: active (running) since Wed 2024-02-21 12:42:40 CET; 1 day 6h ago
       Docs: man:php-fpm8.3(8)
   Main PID: 12273 (php-fpm8.3)
     Status: "Processes active: 0, idle: 2, Requests: 0, slow: 0, Traffic: 0req/sec"
      Tasks: 3 (limit: 1618)
     Memory: 13.5M
     CGroup: /system.slice/php8.3-fpm.service
             |-12273 php-fpm: master process (/etc/php/8.3/fpm/php-fpm.conf)
             |-12275 php-fpm: pool www
             `-12276 php-fpm: pool www

Feb 21 12:42:40 vero systemd[1]: Starting The PHP 8.3 FastCGI Process Manager...
Feb 21 12:42:40 vero systemd[1]: Started The PHP 8.3 FastCGI Process Manager.

Did you follow my advice from yesterday to remove unneeded php versions and all dependency packages?

Apparently not. You have three fpm sockets up and listening. That is like asking for trouble.

Did you read the help from the php-updater script?

Did you follow the steps about how to switch the alternatives?

If you do not (want) to remove unneeded versions then you should at least stop and deactivate the unused services:

sydo systemctl stop php7.3-fpm
sudo systemctl disable php7.3-fpm
sydo systemctl stop php8.3-fpm
sudo systemctl disable php8.3-fpm

that wil prevent the php7.3-fpm and php8.3-fpm from starting automaticaly (and consuming resources)

In a next step, you should switch all php related alternatives to “Manually” 7.4:

for linkgroup in $(ls /var/lib/dpkg/alternatives/ | grep -E "ph(ar|p)"); do sudo update-alternatives --config $linkgroup; done

And of course you have to restart your webserver and php-fpm service after made changes:

sudo systemctl restart nginx php7.4-fpm

What is the echo of

grep -R "fpm" /etc/nginx/sites-enabled

ernolf

At this stage I prefer not to delete alternatives php versions, as it is still possible I can make Nextcloud work with another version than 7.4 and performance is not an issue while the server is not even running.

grep -R “fpm” /etc/nginx/sites-enabled gives :

/etc/nginx/sites-enabled/default: # # With php-fpm (or other unix sockets):
/etc/nginx/sites-enabled/default: # fastcgi_pass unix:/run/php/php7.4-fpm.sock;

I read the php-updater help. While it is a terrific tool (congrats, will definitely use it in the future), I had already modified config files for php 7.4 by hand and changed the socket at this stage (and php7.3 had already been uninstalled by the Debian update… and re-installed afterwards by myself with the sury repo), which limited its pertainability to my situation.

At this stage I will probably completely reinstall Nextcloud, probably using a version supporting php 8.3.3, the latest on my install. I’d rather not have to do that work, but it seems increasingly unlikely that the current install can be recovered. All because of an update, that is an unfortunate fragility.

I compromised and reinstalled version 25 to use the already configured php7.4.

It is working right now, I lost optimisations but it is sufficient for the few months this machine has left.

I kept the former install in a separate location in any case, but we’ll probably never know what went wrong with it.

Anyway, thanks everyone for taking time to help.

1 Like