Skip to content

[Bug]: Cron job fails since update to 29.0.0 #45077

@RastaTaz

Description

@RastaTaz

⚠️ This issue respects the following points: ⚠️

Bug description

Cron job fails to run since update to 29.0.0
As I saw error un WebUI, launched job by hand and got following output:

$ php -f /var/www/nextcloud/cron.php
Cannot load Zend OPcache - it was already loaded
Error: Class "OC\BackgroundJob\TimedJob" not found in /var/www/nextcloud/apps/phonetrack/lib/Cron/AutoExport.php:15
Stack trace:
#0 /var/www/nextcloud/lib/composer/composer/ClassLoader.php(576): include()
#1 /var/www/nextcloud/lib/composer/composer/ClassLoader.php(427): Composer\Autoload\{closure}()
#2 [internal function]: Composer\Autoload\ClassLoader->loadClass()
#3 /var/www/nextcloud/lib/private/AppFramework/Utility/SimpleContainer.php(126): ReflectionClass->__construct()
#4 /var/www/nextcloud/lib/private/AppFramework/Utility/SimpleContainer.php(146): OC\AppFramework\Utility\SimpleContainer->resolve()
#5 /var/www/nextcloud/lib/private/AppFramework/DependencyInjection/DIContainer.php(470): OC\AppFramework\Utility\SimpleContainer->query()
#6 /var/www/nextcloud/lib/private/ServerContainer.php(155): OC\AppFramework\DependencyInjection\DIContainer->queryNoFallback()
#7 /var/www/nextcloud/lib/private/AppFramework/Utility/SimpleContainer.php(64): OC\ServerContainer->query()
#8 /var/www/nextcloud/lib/public/Server.php(55): OC\AppFramework\Utility\SimpleContainer->get()
#9 /var/www/nextcloud/lib/private/BackgroundJob/JobList.php(326): OCP\Server::get()
#10 /var/www/nextcloud/lib/private/BackgroundJob/JobList.php(235): OC\BackgroundJob\JobList->buildJob()
#11 /var/www/nextcloud/cron.php(163): OC\BackgroundJob\JobList->getNext()
#12 {main}

Steps to reproduce

  1. Update to 29.0.0
  2. Switch to 'web' user (nginx in my case)
  3. Launch cron job as it always have been launched before, using "php -f /var/www/nextcloud/cron.php"

Expected behavior

Sucessful cron job

Installation method

Community Manual installation with Archive

Nextcloud Server version

29

Operating system

Debian/Ubuntu

PHP engine version

PHP 8.1

Web server

Nginx

Database engine version

MariaDB

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?

  • Default user-backend (database)
  • LDAP/ Active Directory
  • SSO - SAML
  • Other

Configuration report

{
    "system": {
        "instanceid": "***REMOVED SENSITIVE VALUE***",
        "passwordsalt": "***REMOVED SENSITIVE VALUE***",
        "secret": "***REMOVED SENSITIVE VALUE***",
        "trusted_domains": [
            "cloud.c3dr1c.fr"
        ],
        "datadirectory": "***REMOVED SENSITIVE VALUE***",
        "overwrite.cli.url": "https:\/\/cloud.c3dr1c.fr",
        "overwriteprotocol": "https",
        "version": "29.0.0.19",
        "updater.release.channel": "stable",
        "dbtype": "mysql",
        "dbname": "***REMOVED SENSITIVE VALUE***",
        "dbhost": "***REMOVED SENSITIVE VALUE***",
        "dbtableprefix": "oc_",
        "dbuser": "***REMOVED SENSITIVE VALUE***",
        "dbpassword": "***REMOVED SENSITIVE VALUE***",
        "mysql.utf8mb4": true,
        "installed": true,
        "mail_smtpmode": "smtp",
        "mail_from_address": "***REMOVED SENSITIVE VALUE***",
        "mail_domain": "***REMOVED SENSITIVE VALUE***",
        "mail_smtphost": "***REMOVED SENSITIVE VALUE***",
        "mail_smtpport": "25",
        "defaultapp": "weather",
        "updatechecker": false,
        "maintenance": false,
        "theme": "",
        "loglevel": 0,
        "default_phone_region": "FR",
        "preview_libreoffice_path": "\/usr\/bin\/libreoffice",
        "trashbin_retention_obligation": "auto, 30",
        "memcache.local": "\\OC\\Memcache\\APCu",
        "memcache.locking": "\\OC\\Memcache\\Redis",
        "filesystem_check_changes": 0,
        "filelocking.enabled": true,
        "redis": {
            "host": "***REMOVED SENSITIVE VALUE***",
            "port": 0,
            "dbindex": 51
        },
        "enable_previews": true,
        "enabledPreviewProviders": [
            "OC\\Preview\\PNG",
            "OC\\Preview\\JPEG",
            "OC\\Preview\\GIF",
            "OC\\Preview\\BMP",
            "OC\\Preview\\XBitmap",
            "OC\\Preview\\Movie",
            "OC\\Preview\\PDF",
            "OC\\Preview\\MP3",
            "OC\\Preview\\TXT",
            "OC\\Preview\\MarkDown"
        ],
        "mail_sendmailmode": "smtp",
        "app_install_overwrite": [
            "apporder",
            "radio",
            "audioplayer",
            "maps"
        ],
        "allow_local_remote_servers": true,
        "maintenance_window_start": 2,
        "updater.secret": "***REMOVED SENSITIVE VALUE***"
    }
}

List of activated Apps

Enabled:
  - apporder: 0.15.0
  - audioplayer: 3.4.1
  - calendar: 4.7.0
  - cloud_federation_api: 1.12.0
  - contacts: 6.0.0
  - cospend: 1.6.1
  - dashboard: 7.9.0
  - dav: 1.30.1
  - federatedfilesharing: 1.19.0
  - files: 2.1.0
  - files_downloadlimit: 2.0.0
  - files_pdfviewer: 2.10.0
  - files_reminders: 1.2.0
  - files_sharing: 1.21.0
  - firstrunwizard: 2.18.0
  - logreader: 2.14.0
  - lookup_server_connector: 1.17.0
  - mail: 3.6.0
  - maps: 1.3.1
  - notifications: 2.17.0
  - oauth2: 1.17.0
  - password_policy: 1.19.0
  - phonetrack: 0.7.7
  - photos: 2.5.0
  - privacy: 1.13.0
  - provisioning_api: 1.19.0
  - radio: 1.0.3
  - related_resources: 1.4.0
  - settings: 1.12.0
  - sharebymail: 1.19.0
  - text: 3.10.0
  - theming: 2.4.0
  - twofactor_backupcodes: 1.18.0
  - twofactor_totp: 11.0.0-dev
  - updatenotification: 1.19.1
  - user_status: 1.9.0
  - viewer: 2.3.0
  - weather_status: 1.9.0
  - workflowengine: 2.11.0
Disabled:
  - activity: 2.21.1 (installed 2.8.2)
  - admin_audit: 1.19.0 (installed 1.5.0)
  - bruteforcesettings: 2.9.0
  - circles: 29.0.0-dev (installed 27.0.0)
  - comments: 1.19.0 (installed 1.5.0)
  - contactsinteraction: 1.10.0 (installed 1.8.0)
  - encryption: 2.17.0
  - federation: 1.19.0 (installed 1.5.0)
  - files_external: 1.21.0
  - files_mindmap: 0.0.30 (installed 0.0.30)
  - files_trashbin: 1.19.0 (installed 1.5.0)
  - files_versions: 1.22.0 (installed 1.8.0)
  - nextcloud_announcements: 1.18.0 (installed 1.4.0)
  - recommendations: 2.1.0 (installed 1.6.0)
  - serverinfo: 1.19.0 (installed 1.5.0)
  - support: 1.12.0 (installed 1.0.0)
  - survey_client: 1.17.0 (installed 1.3.0)
  - suspicious_login: 7.0.0
  - systemtags: 1.19.0 (installed 1.5.0)
  - user_ldap: 1.20.0

Nextcloud Signing status

No errors have been found.

Nextcloud Logs

{"reqId":"Nw29opIYT3wrxc4QU3MS","level":3,"time":"2024-04-27T18:36:57+00:00","remoteAddr":"","user":"--","app":"cron","method":"","url":"--","message":"Class \"OC\\BackgroundJob\\TimedJob\" not found","userAgent":"--","version":"29.0.0.19","exception":{"Exception":"Error","Message":"Class \"OC\\BackgroundJob\\TimedJob\" not found","Code":0,"Trace":[{"file":"/var/www/nextcloud/lib/composer/composer/ClassLoader.php","line":576,"function":"include"},{"file":"/var/www/nextcloud/lib/composer/composer/ClassLoader.php","line":427,"function":"Composer\\Autoload\\{closure}","args":["*** sensitive parameters replaced ***"]},{"function":"loadClass","class":"Composer\\Autoload\\ClassLoader","type":"->"},{"file":"/var/www/nextcloud/lib/private/AppFramework/Utility/SimpleContainer.php","line":126,"function":"__construct","class":"ReflectionClass","type":"->"},{"file":"/var/www/nextcloud/lib/private/AppFramework/Utility/SimpleContainer.php","line":146,"function":"resolve","class":"OC\\AppFramework\\Utility\\SimpleContainer","type":"->"},{"file":"/var/www/nextcloud/lib/private/AppFramework/DependencyInjection/DIContainer.php","line":470,"function":"query","class":"OC\\AppFramework\\Utility\\SimpleContainer","type":"->"},{"file":"/var/www/nextcloud/lib/private/ServerContainer.php","line":155,"function":"queryNoFallback","class":"OC\\AppFramework\\DependencyInjection\\DIContainer","type":"->"},{"file":"/var/www/nextcloud/lib/private/AppFramework/Utility/SimpleContainer.php","line":64,"function":"query","class":"OC\\ServerContainer","type":"->"},{"file":"/var/www/nextcloud/lib/public/Server.php","line":55,"function":"get","class":"OC\\AppFramework\\Utility\\SimpleContainer","type":"->"},{"file":"/var/www/nextcloud/lib/private/BackgroundJob/JobList.php","line":326,"function":"get","class":"OCP\\Server","type":"::"},{"file":"/var/www/nextcloud/lib/private/BackgroundJob/JobList.php","line":235,"function":"buildJob","class":"OC\\BackgroundJob\\JobList","type":"->"},{"file":"/var/www/nextcloud/cron.php","line":163,"function":"getNext","class":"OC\\BackgroundJob\\JobList","type":"->"}],"File":"/var/www/nextcloud/apps/phonetrack/lib/Cron/AutoExport.php","Line":15,"message":"Class \"OC\\BackgroundJob\\TimedJob\" not found","exception":{},"CustomMessage":"Class \"OC\\BackgroundJob\\TimedJob\" not found"}}

Additional info

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    0. Needs triagePending check for reproducibility or if it fits our roadmap29-feedbackbug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions