Skip to content

[Bug]: Update Issue to new Nextcloud Version (21.0.7 to 21.0.8) with Addon: user_ldap #30944

Description

@stephanhendl

⚠️ This issue respects the following points: ⚠️

  • This is a bug, not a question or a configuration/webserver/proxy issue.
  • This issue is not already reported on Github (I've searched it).
  • Nextcloud Server is up to date. See Maintenance and Release Schedule for supported versions.
  • I agree to follow Nextcloud's Code of Conduct.

Bug description

Update from 21.0.7 to 21.0.8 leads to an unhandled exception:

2022-01-31T14:18:44+00:00 Updating <user_ldap> ...
An unhandled exception has been thrown:
Error: Call to undefined method OC\DB\QueryBuilder\QueryBuilder::executeQuery() in 
 /var/www/nextcloud/apps/user_ldap/lib/Migration/GroupMappingMigration.php:56
...

Steps to reproduce

  1. Upgrade NC 21.0.7 to 21.0.8 via command line

Expected behavior

No issues during update

Installation method

Manual installation

Operating system

Debian/Ubuntu

PHP engine version

PHP 7.4

Web server

Nginx

Database engine version

MariaDB

Is this bug present after an update or on a fresh install?

Updated from a minor version (ex. 22.2.3 to 22.2.4)

Are you using the Nextcloud Server Encryption module?

No response

What user-backends are you using?

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

Configuration report

Nextcloud or one of the apps require upgrade - only a limited number of commands are available
You may use your browser or the occ upgrade command to do the upgrade
{
    "system": {
        "instanceid": "***REMOVED SENSITIVE VALUE***",
        "passwordsalt": "***REMOVED SENSITIVE VALUE***",
        "secret": "***REMOVED SENSITIVE VALUE***",
        "trusted_domains": [
            "debncl2.ltbbg1.lvnbb.de",
            "10.142.223.118",
            "nextcloud2.landtag.brandenburg.de",
            "127.0.0.1"
        ],
        "datadirectory": "***REMOVED SENSITIVE VALUE***",
        "overwrite.cli.url": "https:\/\/debncl2.ltbbg1.lvnbb.de\/nextcloud",
        "dbtype": "mysql",
        "version": "21.0.7.0",
        "dbname": "***REMOVED SENSITIVE VALUE***",
        "dbhost": "***REMOVED SENSITIVE VALUE***",
        "dbport": "",
        "dbtableprefix": "oc_",
        "dbuser": "***REMOVED SENSITIVE VALUE***",
        "dbpassword": "***REMOVED SENSITIVE VALUE***",
        "installed": true,
        "proxy": "10.128.9.30:80",
        "proxyexclude": [
            "10.*",
            "*.ltbbg1.lvnbb.de",
            "*.lvnbb.de",
            "turn2.landtag.brandenburg.de",
            "62.159.232.102"
        ],
        "memcache.local": "\\OC\\Memcache\\APCu",
        "ldapIgnoreNamingRules": false,
        "ldapProviderFactory": "\\OCA\\User_LDAP\\LDAPProviderFactory",
        "mail_from_address": "***REMOVED SENSITIVE VALUE***",
        "mail_smtpmode": "smtp",
        "mail_smtpauthtype": "PLAIN",
        "mail_domain": "***REMOVED SENSITIVE VALUE***",
        "mail_smtphost": "***REMOVED SENSITIVE VALUE***",
        "mail_smtpport": "25",
        "maintenance": false,
        "log_type": "syslog",
        "logfile": "",
        "loglevel": 0,
        "default_language": "de_DE",
        "defaultapp": "files",
        "updater.release.channel": "stable",
        "mail_sendmailmode": "smtp",
        "mysql.utf8mb4": true,
        "default_phone_region": "DE"
    }
}

List of activated Apps

Nextcloud or one of the apps require upgrade - only a limited number of commands are available
You may use your browser or the occ upgrade command to do the upgrade
Enabled:
  - accessibility: 1.7.0
  - activity: 2.14.3
  - admin_audit: 1.11.0
  - calendar: 3.0.4
  - checksum: 1.1.3
  - cloud_federation_api: 1.4.0
  - comments: 1.11.0
  - contacts: 4.0.7
  - contactsinteraction: 1.2.0
  - dashboard: 7.1.0
  - dav: 1.17.1
  - deck: 1.4.7
  - federatedfilesharing: 1.11.0
  - federation: 1.11.0
  - files: 1.16.0
  - files_external: 1.12.1
  - files_pdfviewer: 2.1.1
  - files_rightclick: 1.0.0
  - files_sharing: 1.13.1
  - files_trashbin: 1.11.0
  - files_versions: 1.14.0
  - files_videoplayer: 1.10.0
  - firstrunwizard: 2.10.0
  - logreader: 2.6.0
  - lookup_server_connector: 1.9.0
  - nextcloud_announcements: 1.10.0
  - notes: 4.2.0
  - notifications: 2.9.0
  - oauth2: 1.9.0
  - password_policy: 1.11.0
  - photos: 1.3.0
  - privacy: 1.5.0
  - provisioning_api: 1.11.0
  - quota_warning: 1.13.0
  - recommendations: 1.0.0
  - serverinfo: 1.11.0
  - settings: 1.3.0
  - sharebymail: 1.11.0
  - spreed: 11.3.4
  - support: 1.4.0
  - survey_client: 1.9.0
  - systemtags: 1.11.0
  - tasks: 0.14.2
  - text: 3.2.0
  - theming: 1.12.0
  - theming_customcss: 1.10.0
  - twofactor_backupcodes: 1.10.0
  - updatenotification: 1.11.0
  - user_ldap: 1.11.1
  - user_status: 1.1.1
  - viewer: 1.5.0
  - weather_status: 1.1.0
  - workflow_script: 1.6.0
  - workflowengine: 2.3.1
Disabled:
  - encryption

Nextcloud Signing status

No errors have been found.

Nextcloud Logs

Jan 31 15:18:44 debncl2 Nextcloud[20493]: {"reqId":"Y0O0KcYxRzWQoo289My3","level":0,"time":"2022-01-31T14:18:44+00:001.0.8.3","userAgent":"--","version":"21.0.7.0"}
Jan 31 15:18:44 debncl2 Nextcloud[20493]: {"reqId":"Y0O0KcYxRzWQoo289My3","level":1,"time":"2022-01-31T14:18:44+00:00for \\OC\\Repair::step: Symfony\\Component\\EventDispatcher\\GenericEvent is used","userAgent":"--","version":"21.0.7
Jan 31 15:18:44 debncl2 Nextcloud[20493]: {"reqId":"Y0O0KcYxRzWQoo289My3","level":1,"time":"2022-01-31T14:18:44+00:00 Repair MySQL collation","userAgent":"--","version":"21.0.7.0"}
Jan 31 15:18:44 debncl2 Nextcloud[20493]: {"reqId":"Y0O0KcYxRzWQoo289My3","level":1,"time":"2022-01-31T14:18:44+00:00for \\OC\\Repair::info: Symfony\\Component\\EventDispatcher\\GenericEvent is used","userAgent":"--","version":"21.0.7
Jan 31 15:18:44 debncl2 Nextcloud[20493]: {"reqId":"Y0O0KcYxRzWQoo289My3","level":1,"time":"2022-01-31T14:18:44+00:00 All tables already have the correct collation -> nothing to do","userAgent":"--","version":"21.0.7.0"}
Jan 31 15:18:44 debncl2 Nextcloud[20493]: {"reqId":"Y0O0KcYxRzWQoo289My3","level":1,"time":"2022-01-31T14:18:44+00:00for \\OC\\Repair::step: Symfony\\Component\\EventDispatcher\\GenericEvent is used","userAgent":"--","version":"21.0.7
Jan 31 15:18:44 debncl2 Nextcloud[20493]: {"reqId":"Y0O0KcYxRzWQoo289My3","level":1,"time":"2022-01-31T14:18:44+00:00 Repair SQLite autoincrement","userAgent":"--","version":"21.0.7.0"}
Jan 31 15:18:44 debncl2 Nextcloud[20493]: {"reqId":"Y0O0KcYxRzWQoo289My3","level":1,"time":"2022-01-31T14:18:44+00:00for \\OC\\Repair::step: Symfony\\Component\\EventDispatcher\\GenericEvent is used","userAgent":"--","version":"21.0.7
Jan 31 15:18:44 debncl2 Nextcloud[20493]: {"reqId":"Y0O0KcYxRzWQoo289My3","level":1,"time":"2022-01-31T14:18:44+00:00 Copy data from accounts table when migrating from ownCloud","userAgent":"--","version":"21.0.7.0"}
Jan 31 15:18:44 debncl2 Nextcloud[20493]: {"reqId":"Y0O0KcYxRzWQoo289My3","level":1,"time":"2022-01-31T14:18:44+00:00for \\OC\\Repair::step: Symfony\\Component\\EventDispatcher\\GenericEvent is used","userAgent":"--","version":"21.0.7
Jan 31 15:18:44 debncl2 Nextcloud[20493]: {"reqId":"Y0O0KcYxRzWQoo289My3","level":1,"time":"2022-01-31T14:18:44+00:00 Drop account terms table when migrating from ownCloud","userAgent":"--","version":"21.0.7.0"}
Jan 31 15:18:44 debncl2 Nextcloud[20493]: {"reqId":"Y0O0KcYxRzWQoo289My3","level":1,"time":"2022-01-31T14:18:44+00:00Updating database schema","userAgent":"--","version":"21.0.7.0"}
Jan 31 15:18:44 debncl2 Nextcloud[20493]: {"reqId":"Y0O0KcYxRzWQoo289My3","level":1,"time":"2022-01-31T14:18:44+00:00d database","userAgent":"--","version":"21.0.7.0"}
Jan 31 15:18:44 debncl2 Nextcloud[20493]: {"reqId":"Y0O0KcYxRzWQoo289My3","level":1,"time":"2022-01-31T14:18:44+00:00: Updating <user_ldap> ...","userAgent":"--","version":"21.0.7.0"}
Jan 31 15:18:46 debncl2 Nextcloud[19845]: {"reqId":"1YgYI0uPFOMo72ZAbgup","level":1,"time":"2022-01-31T14:18:46+00:00essage":"{\"Exception\":\"Symfony\\\\Component\\\\Routing\\\\Exception\\\\RouteNotFoundException\",\"Message\":\"UnabCode\":0,\"Trace\":[{\"file\":\"/var/www/nextcloud/lib/private/Route/Router.php\",\"line\":366,\"function\":\"generat/www/nextcloud/lib/private/Route/CachingRouter.php\",\"line\":60,\"function\":\"generate\",\"class\":\"OC\\\\Route\\\\":\"generate\",\"class\":\"OC\\\\Route\\\\CachingRouter\",\"type\":\"->\"},{\"file\":\"/var/www/nextcloud/apps/filesype\":\"->\"},{\"file\":\"/var/www/nextcloud/lib/private/CapabilitiesManager.php\",\"line\":72,\"function\":\"getCapae/Template/JSConfigHelper.php\",\"line\":183,\"function\":\"getCapabilities\",\"class\":\"OC\\\\CapabilitiesManager\"tConfig\",\"class\":\"OC\\\\Template\\\\JSConfigHelper\",\"type\":\"->\"},{\"file\":\"/var/www/nextcloud/lib/private/"->\"},{\"file\":\"/var/www/nextcloud/lib/private/Template/Base.php\",\"line\":132,\"function\":\"fetchPage\",\"classintPage\",\"class\":\"OC\\\\Template\\\\Base\",\"type\":\"->\"},{\"file\":\"/var/www/nextcloud/lib/base.php\",\"line\ex.php\",\"line\":37,\"function\":\"handleRequest\",\"class\":\"OC\",\"type\":\"::\"}],\"File\":\"/var/www/nextcloud/_http/v2.3.1 (monitoring-plugins 2.3.1)","version":"21.0.7.0"}
Jan 31 15:18:46 debncl2 Nextcloud[19845]: {"reqId":"1YgYI0uPFOMo72ZAbgup","level":1,"time":"2022-01-31T14:18:46+00:00essage":"{\"Exception\":\"Symfony\\\\Component\\\\Routing\\\\Exception\\\\RouteNotFoundException\",\"Message\":\"Unab not exist.\",\"Code\":0,\"Trace\":[{\"file\":\"/var/www/nextcloud/lib/private/Route/Router.php\",\"line\":366,\"func{\"file\":\"/var/www/nextcloud/lib/private/Route/CachingRouter.php\",\"line\":60,\"function\":\"generate\",\"class\":":85,\"function\":\"generate\",\"class\":\"OC\\\\Route\\\\CachingRouter\",\"type\":\"->\"},{\"file\":\"/var/www/nextctype\":\"->\"},{\"file\":\"/var/www/nextcloud/apps/cloud_federation_api/lib/Capabilities.php\",\"line\":45,\"functionprivate/CapabilitiesManager.php\",\"line\":72,\"function\":\"getCapabilities\",\"class\":\"OCA\\\\CloudFederationAPI\ne\":183,\"function\":\"getCapabilities\",\"class\":\"OC\\\\CapabilitiesManager\",\"type\":\"->\"},{\"file\":\"/var/w\\\\JSConfigHelper\",\"type\":\"->\"},{\"file\":\"/var/www/nextcloud/lib/private/legacy/OC_Template.php\",\"line\":18d/lib/private/Template/Base.php\",\"line\":132,\"function\":\"fetchPage\",\"class\":\"OC_Template\",\"type\":\"->\"},\\\\Base\",\"type\":\"->\"},{\"file\":\"/var/www/nextcloud/lib/base.php\",\"line\":942,\"function\":\"checkMaintenanchandleRequest\",\"class\":\"OC\",\"type\":\"::\"}],\"File\":\"/var/www/nextcloud/3rdparty/symfony/routing/Generator/U.1)","version":"21.0.7.0"}

Additional info

logs from "php updater.phar":

Update of code successful.

Should the "occ upgrade" command be executed? [Y/n] Y
Nextcloud or one of the apps require upgrade - only a limited number of commands are available
You may use your browser or the occ upgrade command to do the upgrade
2022-01-31T14:18:44+00:00 Setting log level to debug
2022-01-31T14:18:44+00:00 Repair step: Repair MySQL collation
2022-01-31T14:18:44+00:00 Repair info: All tables already have the correct collation -> nothing to do
2022-01-31T14:18:44+00:00 Repair step: Repair SQLite autoincrement
2022-01-31T14:18:44+00:00 Repair step: Copy data from accounts table when migrating from ownCloud
2022-01-31T14:18:44+00:00 Repair step: Drop account terms table when migrating f rom ownCloud
2022-01-31T14:18:44+00:00 Updating database schema
2022-01-31T14:18:44+00:00 Updated database
2022-01-31T14:18:44+00:00 Updating <user_ldap> ...
An unhandled exception has been thrown:
Error: Call to undefined method OC\DB\QueryBuilder\QueryBuilder::executeQuery()  in /var/www/nextcloud/apps/user_ldap/lib/Migration/GroupMappingMigration.php:56
Stack trace:
#0 /var/www/nextcloud/apps/user_ldap/lib/Migration/Version1130Date20220110154717.php(54): OCA\User_LDAP\Migration\GroupMappingMigration->copyGroupMappingData()
#1 /var/www/nextcloud/lib/private/DB/MigrationService.php(528): OCA\User_LDAP\Migration\Version1130Date20220110154717->preSchemaChange()
#2 /var/www/nextcloud/lib/private/DB/MigrationService.php(426): OC\DB\MigrationService->executeStep()
#3 /var/www/nextcloud/lib/private/legacy/OC_App.php(1012): OC\DB\MigrationService->migrate()
#4 /var/www/nextcloud/lib/private/Updater.php(347): OC_App::updateApp()
#5 /var/www/nextcloud/lib/private/Updater.php(262): OC\Updater->doAppUpgrade()
#6 /var/www/nextcloud/lib/private/Updater.php(134): OC\Updater->doUpgrade()
#7 /var/www/nextcloud/core/Command/Upgrade.php(249): OC\Updater->upgrade()
#8 /var/www/nextcloud/3rdparty/symfony/console/Command/Command.php(255): OC\Core\Command\Upgrade->execute()
#9 /var/www/nextcloud/3rdparty/symfony/console/Application.php(1009): Symfony\Component\Console\Command\Command->run()
#10 /var/www/nextcloud/3rdparty/symfony/console/Application.php(273): Symfony\Component\Console\Application->doRunCommand()
#11 /var/www/nextcloud/3rdparty/symfony/console/Application.php(149): Symfony\Component\Console\Application->doRun()
#12 /var/www/nextcloud/lib/private/Console/Application.php(215): Symfony\Component\Console\Application->run()
#13 /var/www/nextcloud/console.php(100): OC\Console\Application->run()
#14 /var/www/nextcloud/occ(11): require_once('/var/www/nextcl...')
#15 {main}

Metadata

Metadata

Assignees

No one assigned

    Labels

    0. Needs triagePending check for reproducibility or if it fits our roadmapbug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions