New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug]: cron.php not working due to Cannot declare class OC\Command\CommandJob, because the name is already in use #44565
Comments
Why is your configuration report outputing version |
Because I have a 90mb logfile running since at least one year. If you want me to upload the entire file then I can do so but it's full of the same messages. Here's a fresh entry for this:
|
Can you briefly enable |
@joshtrichards should this affect running via EDIT{
"reqId": "g4qYPOX5Jldi3MClKOEy",
"level": 3,
"time": "2024-03-29T13:44:25+00:00",
"remoteAddr": "",
"user": "--",
"app": "PHP",
"method": "",
"url": "--",
"message": "Cannot declare class OC\\Command\\CommandJob, because the name is already in use at /srv/www/cloud.frelia.org/lib/private/Command/CommandJob.php#31",
"userAgent": "--",
"version": "28.0.4.1",
"data": {
"app": "PHP",
"backtrace": [
{
"file": "/srv/www/cloud.frelia.org/lib/private/Log.php",
"line": 139,
"function": "log",
"class": "OC\\Log",
"type": "->"
},
{
"file": "/srv/www/cloud.frelia.org/lib/private/Log/PsrLoggerAdapter.php",
"line": 110,
"function": "critical",
"class": "OC\\Log",
"type": "->"
},
{
"file": "/srv/www/cloud.frelia.org/lib/private/Log/ErrorHandler.php",
"line": 58,
"function": "critical",
"class": "OC\\Log\\PsrLoggerAdapter",
"type": "->"
},
{
"function": "onShutdown",
"class": "OC\\Log\\ErrorHandler",
"type": "->"
}
]
}
} Doesn't look helpful though |
Yeah I was worried that might be the case since this is a PHP fatal error. sigh I don't see how this is coming from our code base. We don't declare that class anywhere else and there haven't been other similar reports. (We'd no doubt have a ton fairly quickly after it appearing). I don't see anything within the apps you have installed either. A shot in the dark: Can you share the output of
What's the history of this installation? Has it been around awhile or is it fairly new? Also, how do you typically deploy updates? |
Also, what's the output of: |
@joshtrichards as you would expect:
It has been around since... at least May 2018. At least that's what the timestamp on my data directory indicates. I usually deploy using the Web UI and before that I manually extracted tarballs.
|
Any chance you're sharing your Redis server with a second Nextcloud instance? Also can you see if changing your
(I'm assuming this is a standalone server; in which case APCu is recommended for |
Nope. That's a single small VPS running a single Nextcloud instance.
Lemme do it. |
Uh, I'm confused as hell right now:
but EDITOnce, again, I realized I'm a dummy so:
It appears we're back to square one |
Have you customized your PHP runtime configuration at all? Share the output of:
|
@joshtrichards there you go Details
|
I see you have the extension
|
|
Bug description
My background jobs systemd service is constantly failing with:
PHP Fatal error: Cannot declare class OC\Command\CommandJob, because the name is already in use in /srv/www/cloud.frelia.org/lib/private/Command/CommandJob.php on line 31
Steps to reproduce
sudo -u www-data php /srv/www/cloud.frelia.org/cron.php
Expected behavior
cron.php runs normally
Installation method
Community Manual installation with Archive
Nextcloud Server version
28
Operating system
Debian/Ubuntu
PHP engine version
PHP 8.3
Web server
Nginx
Database engine version
PostgreSQL
Is this bug present after an update or on a fresh install?
Upgraded to a MAJOR version (ex. 22 to 23)
Are you using the Nextcloud Server Encryption module?
Encryption is Disabled
What user-backends are you using?
Configuration report
List of activated Apps
Nextcloud Signing status
Nextcloud Logs
Additional info
Based on the error above it appears I have had the issue since version 27 at least
So far I tried:
The text was updated successfully, but these errors were encountered: