Netxcloud : Internal Server Error

My YunoHost server

Hardware: Raspberry Pi at home
YunoHost version: 11.2.22
I have access to my server : SSH | webadmin |
Are you in a special context or did you perform some particular tweaking on your YunoHost instance ? : no / yes
If your request is related to an app, specify its name and version: Nextcloud 29.0.2~ynh1

Description of my issue

I noticed my Nextcloud shows on his URL :

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.

On webadmin interface :

Une erreur empĂȘche l'affichage du panneau de configuration :

Échec de la lecture au retour du script /etc/yunohost/apps/nextcloud/scripts/config. Erreur : Fichier YAML corrompu en lecture depuis /tmp/tmpo637se9d/stdreturn (raison : mapping values are not allowed here<br> in "<unicode string>", line 9, column 60:<br> ... s been thrown: OCP\HintException: [0]: Memcache OC\Memcache\APCu ... <br> ^). Contenu brut : fpm_footprint:<br> high<br>fpm_free_footprint:<br> 0<br>fpm_usage: 'medium'<br>maintenance_mode:<br> 1<br>system_addressbook_exposed:<br> An unhandled exception has been thrown: OCP\HintException: [0]: Memcache OC\Memcache\APCu not available for local cache (Is the matching PHP module installed and enabled?)<br>

Merci de signaler cette erreur à l'équipe de YunoHost pour qu'elle soit corrigée !

I restore a backup after deleting the app, same problem.

Thx for your help :slight_smile:

In /var/mail/nextcloud/

I see many mails
 1 sent evey 5 minutes
 the last one :
[
]
Subject: Cron <nextcloud@XXX> /usr/bin/php8.2 --define apc.enable_cli=1 -f /var/www/nextcloud/cron.php
[
]
OCP\HintException: [0]: Memcache OC\Memcache\APCu not available for local cache (Is the matching PHP module installed and enabled?)

If it can help


A fresh install on another subdomain I own is ok. Everything is empty, but working.

Is there something to verify with this new instance, to control on the old crashed one ?

On new instance :

On old crashed instance :

Thx for your help :slight_smile:

I have at some point the same issue. I wanted to take a look at the log, but there is no log in /home/yunohost.app/nextcloud/data/


Help would be appreciated.

I have the same issues as described above.

I checked /var/log/nextcloud/nextcloud.log and came across these messages repeating:

{“reqId”:“WvAzoJOPyoUN5RQHbQHs”,“level”:3,“time”:“2024-07-25T00:00:18+00:00”,“remoteAddr”:“”,“user”:“–”,“app”:“PHP”,“method”:“”,“url”:“–”,“message”:“Undefined array key 4 at /var/www/nextcloud/3rdparty/wapmorgan/mp3info/src/Mp3Info.php#388”,“userAgent”:“–”,“version”:“29.0.2.2”,“data”:{“app”:“PHP”}}
{“reqId”:“WvAzoJOPyoUN5RQHbQHs”,“level”:3,“time”:“2024-07-25T00:00:18+00:00”,“remoteAddr”:“”,“user”:“–”,“app”:“PHP”,“method”:“”,“url”:“–”,“message”:“Trying to access array offset on value of type null at /var/www/nextcloud/3rdparty/wapmorgan/mp3info/src/Mp3Info.php#388”,“userAgent”:“–”,“version”:“29.0.2.2”,“data”:{“app”:“PHP”}}
{“reqId”:“WvAzoJOPyoUN5RQHbQHs”,“level”:3,“time”:“2024-07-25T00:00:18+00:00”,“remoteAddr”:“”,“user”:“–”,“app”:“PHP”,“method”:“”,“url”:“–”,“message”:“Undefined array key 4 at /var/www/nextcloud/3rdparty/wapmorgan/mp3info/src/Mp3Info.php#397”,“userAgent”:“–”,“version”:“29.0.2.2”,“data”:{“app”:“PHP”}}
{“reqId”:“WvAzoJOPyoUN5RQHbQHs”,“level”:3,“time”:“2024-07-25T00:00:18+00:00”,“remoteAddr”:“”,“user”:“–”,“app”:“PHP”,“method”:“”,“url”:“–”,“message”:“Trying to access array offset on value of type null at /var/www/nextcloud/3rdparty/wapmorgan/mp3info/src/Mp3Info.php#397”,“userAgent”:“–”,“version”:“29.0.2.2”,“data”:{“app”:“PHP”}}
{“reqId”:“WvAzoJOPyoUN5RQHbQHs”,“level”:2,“time”:“2024-07-25T00:00:20+00:00”,“remoteAddr”:“”,“user”:“–”,“app”:“cron”,“method”:“”,“url”:“–”,“message”:“Used memory grew by more than 10 MB when executing job OC\Core\BackgroundJobs\GenerateMetadataJob (id: 932, arguments: null): 47.5 MB (before: 35.6 MB)”,“userAgent”:“–”,“version”:“29.0.2.2”,“data”:{“app”:“cron”}}

Rather, the mp3info messages were repeating while the last one was on its own.

Anyway, I found this thread about the mp3info part of previews. I add to the /var/www/nextcloud/config/config.php this phrase:

'enable_previews' => false,

This seems to have stopped the log messages, but has not resolved the other described problems.

I uninstalled nextcloud (the app, not the data) and restored the pre-upgrade backup (version 28.05) to its subdomain, and it is working normally again.

I have the same problem for 2 days. Since last Nextcloud update.

At the same time, I got a mail telling me that my domain has been blacklisted because of too many queries


[ERROR] Votre IP ou domaine 37.187.3.128 est sur liste noire sur SenderScore Blacklist

I only send an e-mail from time to time.

Could there be a link between these 2 problems ?

Possible, I see in my stats Nextcloud is sending to root or itself near 300 emails / day


Where can I find these stats ?

I found something in the admin page for my Nextcloud :

Une erreur empĂȘche l’affichage du panneau de configuration :

Échec de la lecture au retour du script /etc/yunohost/apps/nextcloud/scripts/config. Erreur : Fichier YAML corrompu en lecture depuis /tmp/tmpmu45w1zb/stdreturn (raison : mapping values are not allowed here
in “”, line 9, column 60:

 s been thrown: OCP\HintException: [0]: Memcache OC\Memcache\APCu 

^). Contenu brut : fpm_footprint:
high
fpm_free_footprint:
0
fpm_usage: ‘medium’
maintenance_mode:
1
system_addressbook_exposed:
An unhandled exception has been thrown: OCP\HintException: [0]: Memcache OC\Memcache\APCu not available for local cache (Is the matching PHP module installed and enabled?)

Merci de signaler cette erreur Ă  l’équipe de YunoHost pour qu’elle soit corrigĂ©e !

The file /tmp/tmpmu45w1zb/stdreturn does not exist. How could it be corrupted ?

1 Like

Same problem here, it looks like a bug, and not a problem related to our config or hardware failure.

I see many many mails in nextcloud mail folder, to watch them, with root :
ls -l /var/mail/nextcloud/new/
then you can read the mail with :
cat /var/mail/nextcloud/new/CHANGEME

And optionally, you can add a script to receive your mail server stats every day with :

WTF ! There are 1397 new mails
 Here is the last one (I only change domain to my.domain) :

Return-Path: nextcloud@my.domain
Delivered-To: nextcloud@my.domain
Received: by my.domain (Postfix, from userid 998)
id BF1AC4575D; Fri, 26 Jul 2024 13:20:01 +0200 (CEST)
From: root@my.domain (Cron Daemon)
To: nextcloud@my.domain
Subject: Cron nextcloud@my.domain /usr/bin/php8.2 --define >apc.enable_cli=1 -f /var/www/nextcloud/cron.php
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-Cron-Env: <SHELL=/bin/sh>
X-Cron-Env: <HOME=/var/www/nextcloud>
X-Cron-Env: <PATH=/usr/bin:/bin>
X-Cron-Env: <LOGNAME=nextcloud>
Message-Id: 20240726112001.BF1AC4575D@my.domain
Date: Fri, 26 Jul 2024 13:20:01 +0200 (CEST)

OCP\HintException: [0]: Memcache OC\Memcache\APCu not available for local cache (Is the matching PHP module installed and enabled?)

3 of them in February and March. Everything else during last 4 days.

Any idea of the meaning of that message ? Memcache, APCu, which PHP module ?

Thx for the script. I’ll have a look at it.

I checked /var/mail/nextcloud/new, also hundreds of mails containing “OCP\HintException: [0]: Memcache OC\Memcache\APCu not available for local cache (Is the matching PHP module installed and enabled?)”

I’m not sure
 but may be another way to explore ?

Humm, I see on my Nextcloud install and backup files, it’s using php 8.2
My new test install is using php 8.3

On
ls -l /etc/php/8.2/mods-available/
I don’t see any apcu.ini
ls -l /etc/php/8.3/mods-available/
apcu.ini is here
Not sure it’s related, but why not


Humm, how to force current Nextcloud to use php 8.3 without the webpage (because this one is broken
) ?

This way was the good one :stuck_out_tongue_closed_eyes:

Problem solved with installing the apcu package for php8.2, the php version my Nextcloud looks like using
 (if I’m not wrong)

with root
apt install php8.2-apcu
systemctl restart nginx
et voilĂ  :kissing:

No more Internal Server Error
and webpage application configuration is ok.

1 Like

I confirm. This solved my problem too.
Thanks

1 Like

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.