The admin manual has been changed to reflect this change of design only recently, I presume. This seems to be an intentional change to the PHP coding in NC 22 and obviously was backported to NC 21.0.3 without any notice to the community. Please prove me wrong, but this is my picture after reading the below reports which are one month old.
If this is the case, this apparent negligence and way of change from Nextcloud would be especially hurting to community people like me who were running a stable NC environment for years.
I had this setting configured before, so somewhere this must have been communicated. This is also the reason why I assumed that the upgrade of the PHP packages caused the error, because I had already made this confiiguration change before.
I’m not a developer and don’t understand half of the linked GitHub threads But it seems to me that APCu should be abandoned as the local cache and that Redis should be used for local caching to avoid problems in the future… Correct me if I’m misinterpreting this…
I think it’s a problem with the 21.0.3 update. Nothing above helps for me.
I decided to restore a backup with V 21.0.2. This works fine again. The problems with the cron’s and APCu begun with the update to V21.0.3.
I have another NC server which I updated from 20.0.11 to 21.0.3. Here I have no such problems with Cron and APCu.
Then the two servers are not configured identically.
Unfortunately, I can’t say exactly what the problem was in my case, because as I mentioned earlier, I updated the PHP packages and then immediately updated to NC 21.0.3. Either the update of the PHP packages or the update of the Nexcloud obviously changed something in the PHP configuration. However, since I document all my installation steps and configurations, I was able to solve the problem in 5 minutes by simply reconfiguring PHP.
I updated only NC, no PHP update or anything and the error occured.
I went back to NC 21.0.2 with a backup and now it workls fine again.
I did some tests. I did a fresh installation of 21.0.3 on a second DiskStation (another Firmware version) and as soon as I enabled APCu the cron stopped. I did then a dffresh installation of 21.0.2 and the croin stayed intact after enabling APCu.
Here is the solution for Synology:
Create the file /usr/local/etc/php74/cli/conf.d/user_settings.ini with following content:
So far I think it’s safe to say, that the parameter apc.enable_cli = 1 is mandatory for the cronjobs to continue to work if one uses APCu for local caching. In my opinion, however, this parameter has been recommended or even required for quite some time. It also says so in the documentation starting from v13… https://docs.nextcloud.com/server/13/admin_manual/configuration_server/caching_configuration.html#id1
I have the same problem with Cron when migrating to 20.0.3. But I am running Nextcloud on a SYNOLOGY DSM. PHP 7.4, MariaDB 10, Apache2.4.
In WEB Station Configuration, PHP parameters, I gave to apc.enable_cli the value of 1 and it brakes instantly my Nextcloud Installation : internal server error.
I restored Nextcloud in 21.0.2 and Web Server in its previous configuration. It’s ok.
Is anyone using Synology and has changed apc.enable_cli to 1 with success ?
Thank you !
Thank you, but, it didn’t work for me…
I created the file
I migrated to NC 21.0.3
No error in Syno CRON JOB Task, but still the message in NC : an error occurred…
I modified apc.enable_cli=1 in webserver
Same message appeared : Internal Server Error
Hello Pierre,
I also have a Synology with NextCloud, having the same issue (when I migrated to the 21.0.3 version).
The difference is that I migrated also to DSM 7
I changed the value apc.enable_cli=1 in WebStation. It didn’t break anything, but it didn’t either changed the cron from returning an error.
cheers,
Laurent.
Hi all,
I have the same problem with my NC instance on my lab server. NC runs as a Docker container, and I strictly don’t know where’s the incriminated file /etc/php/7.4/mods-available/apcu.ini, so I can’t verify the appropriate settings.
Can anyone help me in this context? Thanks in advance!
This has nothing to do with the issue at hand. The parameter apc.enable_cli = 1 should be used in any case if you use APCu as local cache, no matter if you use systemd, crontab or any other tool to execute the cron.php.