NextCloudPi version: 1.49.1
Nextcloud version (eg, 20.0.5): 24.0.3.2
Operating system and version (eg, Ubuntu 20.04): Debian 11
Apache or nginx version (eg, Apache 2.4.25): 2.4.54
PHP version (eg, 7.4): 7.4.30
The issue you are facing:
I’m running Nextcloud in an NextCloudPi Docker container. I also have auto-updates running.
The other day I got a notification that the version of Nextcloud that my system had just auto-updated to couldn’t run on the old PHP version my container was running. I figured that was probably a sign that it was time to just update the container.
When I tried to run nc-backup as a precaution in case something went wrong with the new container, I couldn’t because Nextcloud couldn’t run (because of the PHP issue). So I figured I had to roll the dice.
Unfortunately, after deploying the latest container, I’m encountering some issues. First, in the main web interface (not the NCP admin interface) I’m getting sporadic internal server errors. If I hit refresh 1-5 times, whatever page I’m accessing eventually loads.
The other major issue is that most of my apps stopped working. Most importantly, the 2FA TOTP app stopped functioning. For the time being I’m able to use my backup codes, but I’d really like to get that working again. Perhaps related, I can’t access the App Store. I can get to the Apps page, but I can only see apps that are already on my system–I appear to be able to enable/disable those, but I haven’t tried.
I’m hoping/wondering if this is a common issue with the latest upgrade or newest container, and am crossing my fingers that there’s a known way to resolve it. (I’ve tried looking through the forums, but sadly haven’t found anything.)
I’m very grateful for any advice or help!
Is this the first time you’ve seen this error? Y
Steps to replicate it:
- Auto-upgrade to latest NextCloud version
- Receive notification that PHP is out of date
- Update NextCloudPi container to latest
The output of your Nextcloud log in Admin > Logging (contains thousands of lines like the following):
{"reqId":"YyftW-6NkQ4LxomA3uI46gAAABU","level":3,"time":"2022-09-19T04:17:31+00:00","remoteAddr":"router address","user":"--","app":"core","method":"GET","url":"/index.php/apps/serverinfo/update","message":"NOAUTH Authentication required.","userAgent":"Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/105.0.0.0 Safari/537.36","version":"24.0.3.2","exception":{"Exception":"RedisException","Message":"NOAUTH Authentication required.","Code":0,"Trace":[{"file":"/data/nextcloud/lib/private/Memcache/Redis.php","line":48,"function":"get","class":"Redis","type":"->"},{"file":"/data/nextcloud/lib/private/App/InfoParser.php","line":58,"function":"get","class":"OC\\Memcache\\Redis","type":"->"},{"file":"/data/nextcloud/lib/private/App/AppManager.php","line":506,"function":"parse","class":"OC\\App\\InfoParser","type":"->"},{"file":"/data/nextcloud/lib/private/App/AppManager.php","line":521,"function":"getAppInfo","class":"OC\\App\\AppManager","type":"->"},{"file":"/data/nextcloud/lib/private/legacy/OC_App.php","line":568,"function":"getAppVersion","class":"OC\\App\\AppManager","type":"->"},{"file":"/data/nextcloud/lib/private/legacy/OC_App.php","line":891,"function":"getAppVersion","class":"OC_App","type":"::"},{"file":"/data/nextcloud/lib/private/legacy/OC_Util.php","line":1225,"function":"shouldUpgrade","class":"OC_App","type":"::"},{"file":"/data/nextcloud/lib/public/Util.php","line":579,"function":"needUpgrade","class":"OC_Util","type":"::"},{"file":"/data/nextcloud/lib/private/legacy/OC_Template.php","line":116,"function":"needUpgrade","class":"OCP\\Util","type":"::"},{"file":"/data/nextcloud/lib/private/legacy/OC_Template.php","line":78,"function":"initTemplateEngine","class":"OC_Template","type":"::"},{"file":"/data/nextcloud/lib/private/legacy/OC_Template.php","line":324,"function":"__construct","class":"OC_Template","type":"->"},{"file":"/data/nextcloud/index.php","line":74,"function":"printExceptionErrorPage","class":"OC_Template","type":"::"}],"File":"/data/nextcloud/lib/private/Memcache/Redis.php","Line":48,"CustomMessage":"--"}
The output of your config.php file in /path/to/nextcloud
(make sure you remove any identifiable information!):
$CONFIG = array (
'passwordsalt' => 'XYZ,
'secret' => 'XYZ,
'trusted_domains' =>
array (
0 => 'localhost',
11 => 'XYZ',
1 => 'XYZ',
5 => 'nextcloudpi.local',
7 => 'nextcloudpi',
8 => 'nextcloudpi.lan',
6 => 'XYZ',
20 => 'XYZ',
21 => 'XYZ',
22 => '_',
3 => 'localhost',
14 => 'XYZ',
'' => 'localhost',
),
'datadirectory' => '/data/nextcloud/data',
'dbtype' => 'mysql',
'version' => '24.0.3.2',
'overwrite.cli.url' => 'https://localhost/',
'dbname' => 'nextcloud',
'dbhost' => 'localhost',
'dbport' => '',
'dbtableprefix' => 'oc_',
'mysql.utf8mb4' => true,
'dbuser' => 'ncadmin',
'dbpassword' => 'XYZ',
'installed' => true,
'instanceid' => 'XYZ',
'memcache.local' => '\\OC\\Memcache\\Redis',
'memcache.locking' => '\\OC\\Memcache\\Redis',
'redis' =>
array (
'host' => '/var/run/redis/redis.sock',
'port' => 0,
'timeout' => 0.0,
'password' => 'XYZ',
),
'tempdirectory' => '/var/www/nextcloud/data/tmp',
'mail_smtpmode' => 'sendmail',
'mail_smtpauthtype' => 'LOGIN',
'mail_from_address' => 'admin',
'mail_domain' => 'ownyourbits.com',
'preview_max_x' => '2048',
'preview_max_y' => '2048',
'jpeg_quality' => '60',
'overwriteprotocol' => 'https',
'trusted_proxies' =>
array (
0 => 'XYZ',
1 => 'XYZ',
2 => '_',
11 => 'XYZ',
12 => '::1',
13 => 'localhost',
14 => '',
),
'twofactor_enforced' => 'true',
'twofactor_enforced_groups' =>
array (
0 => '2FA',
),
'twofactor_enforced_excluded_groups' =>
array (
),
'maintenance' => false,
'loglevel' => 2,
'theme' => '',
);
The output of your Apache/nginx/system log in /var/log/____
(error.log contains thousands of lines as follows):
[Sun Sep 18 20:29:03.626843 2022] [proxy_fcgi:error] [pid 123:tid 140074737964800] [client 'container IP':46588] AH01071: Got error 'PHP message: PHP Fatal error: Uncaught Doctrine\\DBAL\\Exception: Failed to connect to the database: An exception occurred in the driver: SQLSTATE[HY000] [1045] Access denied for user 'ncadmin'@'localhost' (using password: YES) in /data/nextcloud/lib/private/DB/Connection.php:139\nStack trace:\n#0 /data/nextcloud/3rdparty/doctrine/dbal/src/Connection.php(1519): OC\\DB\\Connection->connect()\n#1 /data/nextcloud/3rdparty/doctrine/dbal/src/Connection.php(1041): Doctrine\\DBAL\\Connection->getWrappedConnection()\n#2 /data/nextcloud/lib/private/DB/Connection.php(261): Doctrine\\DBAL\\Connection->executeQuery()\n#3 /data/nextcloud/3rdparty/doctrine/dbal/src/Query/QueryBuilder.php(345): OC\\DB\\Connection->executeQuery()\n#4 /data/nextcloud/lib/private/DB/QueryBuilder/QueryBuilder.php(281): Doctrine\\DBAL\\Query\\QueryBuilder->execute()\n#5 /data/nextcloud/lib/private/AppConfig.php(411): OC\\DB\\QueryBuilder\\QueryBuilder->execute()\n#6 /data/nextcloud/lib/private/AppConfig.php(176): OC\\AppConfig->loadConfigValues()\n#7 /data/n...'