镜像站点 · 本页由第三方 GitHub 只读镜像提供,非 GitHub 官方站点,不接受任何登录或凭据输入。前往 github.com
Skip to content

[Bug]: 24.0.0 beta 2, InvalidArgumentException: Column "oc_fulltextsearch_indexes"."message" is type String, but exceeding the 4.000 length limit. #31791

Closed

Description

@SDuesterhaupt

⚠️ 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

Within the update process (version 24.0.0 beta 2) I receive this exception:

InvalidArgumentException: Column "oc_fulltextsearch_indexes"."message" is type String, but exceeding the 4.000 length limit.

The upgrade procedure cannot be accomplished.

Steps to reproduce

$ sudo -u apache php /var/www/<***>/updater/updater.phar

Current version is 24.0.0 beta 2.

Update to Nextcloud 24.0.0 beta 2 available. (channel: "beta")
Following file will be downloaded automatically: https://download.nextcloud.com/server/prereleases/nextcloud-24.0.0beta2.zip

Steps that will be executed:
[✔] Check for expected files
[✔] Check for write permissions
[✔] Create backup
[✔] Downloading
[✔] Verify integrity
[✔] Extracting
[✔] Enable maintenance mode
[✔] Replace entry points
[✔] Delete old files
[✔] Move new files in place
[✔] Done

Continue update? [y/N] y

Info: Pressing Ctrl-C will finish the currently running step and then stops the updater.

[✔] Check for expected files
[✔] Check for write permissions
[✔] Create backup
[✔] Downloading
[✔] Verify integrity
[✔] Extracting
[✔] Enable maintenance mode
[✔] Replace entry points
[✔] Delete old files
[✔] Move new files in place
[✔] Done

Update of code successful.

Should the "occ upgrade" command be executed? [Y/n]
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-04-01T17:27:02+02:00 Setting log level to debug
2022-04-01T17:27:02+02:00 Repair step: Repair MySQL collation
2022-04-01T17:27:02+02:00 Repair info: All tables already have the correct collation -> nothing to do
2022-04-01T17:27:02+02:00 Repair step: Repair SQLite autoincrement
2022-04-01T17:27:02+02:00 Repair step: Copy data from accounts table when migrating from ownCloud
2022-04-01T17:27:02+02:00 Repair step: Drop account terms table when migrating from ownCloud
2022-04-01T17:27:02+02:00 Updating database schema
2022-04-01T17:27:02+02:00 Updated database
2022-04-01T17:27:02+02:00 Updating <files_external> ...
2022-04-01T17:27:03+02:00 InvalidArgumentException: Column "oc_fulltextsearch_indexes"."message" is type String, but exceeding the 4.000 length limit.
2022-04-01T17:27:03+02:00 Update failed
2022-04-01T17:27:03+02:00 Maintenance mode is kept active
2022-04-01T17:27:03+02:00 Resetting log level

Expected behavior

The upgrade procedure should be finished successfully.

Installation method

Manual installation

Operating system

RHEL/CentOS

PHP engine version

PHP 8.0

Web server

Apache (supported)

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?

Encryption is Disabled

What user-backends are you using?

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

Configuration report

No response

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.10.0
  - activity: 2.16.0
  - admin_audit: 1.14.0
  - calendar: 3.2.2
  - circles: 24.0.0-alpha1
  - cloud_federation_api: 1.7.0
  - comments: 1.14.0
  - contactsinteraction: 1.5.0
  - dashboard: 7.4.0
  - dav: 1.22.0
  - federatedfilesharing: 1.14.0
  - federation: 1.14.0
  - files: 1.19.0
  - files_external: 1.16.0
  - files_pdfviewer: 2.5.0
  - files_rightclick: 1.3.0
  - files_sharing: 1.16.0
  - files_trashbin: 1.14.0
  - files_versions: 1.17.0
  - files_videoplayer: 1.13.0
  - firstrunwizard: 2.13.0
  - logreader: 2.9.0
  - lookup_server_connector: 1.12.0
  - mail: 1.11.7
  - nextcloud_announcements: 1.13.0
  - notifications: 2.12.0
  - oauth2: 1.12.0
  - password_policy: 1.14.0
  - photos: 1.6.0
  - privacy: 1.8.0
  - provisioning_api: 1.14.0
  - recommendations: 1.3.0
  - serverinfo: 1.14.0
  - settings: 1.6.0
  - sharebymail: 1.14.0
  - support: 1.7.0
  - survey_client: 1.12.0
  - systemtags: 1.14.0
  - text: 3.5.1
  - theming: 1.15.0
  - twofactor_backupcodes: 1.13.0
  - updatenotification: 1.14.0
  - user_status: 1.4.0
  - viewer: 1.8.0
  - workflowengine: 2.6.0
Disabled:
  - encryption
  - files_fulltextsearch: 23.0.0
  - files_fulltextsearch_tesseract: 22.0.0
  - files_markdown: 2.3.5
  - fulltextsearch: 23.0.0
  - fulltextsearch_elasticsearch: 23.0.0
  - user_ldap
  - weather_status: 1.0.0

Nextcloud Signing status

No response

Nextcloud Logs

No response

Additional info

No response

Activity

  1. SDuesterhaupt commented on Apr 1, 2022

    @SDuesterhaupt
    Author

    As temporary workarround I simply dropped the tables with

    drop table oc_fulltextsearch_indexes;
    drop table oc_fulltextsearch_ticks;
    

    Currently the apps 'fulltextsearch' are disabled. In the case of need the index can be rebuild.

  2. danir-de commented on Apr 1, 2022

    @danir-de

    Same thing with the app forms.

    # occ upgrade
    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
    Setting log level to debug
    Updating database schema
    Updated database
    Updating <files_external> ...
    InvalidArgumentException: Column "oc_forms_v2_answers"."text" is type String, but exceeding the 4.000 length limit.
    Update failed
    

    Seems to be happening in all app tables, where there is a VARCHAR field with more then 4000 length.

    InvalidArgumentException: Column "oc_forms_v2_answers"."text" is type String, but exceeding the 4.000 length limit.
    Update failed
    InvalidArgumentException: Column "oc_ldap_group_mapping"."ldap_dn" is type String, but exceeding the 4.000 length limit.
    Update failed
    InvalidArgumentException: Column "oc_forms_v2_forms"."description" is type String, but exceeding the 4.000 length limit.
    Update failed
    

    By setting them all to 4000 (from 4096, 8192, etc.) you can finish the update after a few tries.

  3. szaimen commented on Apr 1, 2022

    @szaimen
    Contributor
  4. leuedaniel commented on Apr 2, 2022

    @leuedaniel

    Same at "oc_cas_ticket"."service" and "oc_external_config"."value"
    Change the length from 4096 to 4000 in the database works for me.

  5. szaimen commented on Apr 2, 2022

    @szaimen
    Contributor
  6. sosed213 commented on Apr 2, 2022

    @sosed213

    InvalidArgumentException: Column "oc_bookmarks_folders_public"."description" is type String, but exceeding the 4.000 length limit.

  7. DoM1niC commented on Apr 2, 2022

    @DoM1niC

    I got a similar issue but here is only the files_external App affected, any workaround increase the VARCHAR is not helping here

    InvalidArgumentException: Column "oc_ldap_group_mapping"."ldap_dn" is type String, but exceeding the 4.000 length limit.
    Update failed
    
  8. TheMrApostel commented on Apr 2, 2022

    @TheMrApostel

    I got a similar issue but here is only the files_external App affected, any workaround increase the VARCHAR is not helping here

    InvalidArgumentException: Column "oc_ldap_group_mapping"."ldap_dn" is type String, but exceeding the 4.000 length limit.
    Update failed
    

    You have to reduce it, not increase it.
    Try:
    alter table oc_ldap_group_mapping CHANGE COLUMN 'ldap_dn' varchar(4000);

  9. sosed213 commented on Apr 2, 2022

    @sosed213

    I was able to find and shorten several fields in tables. After that the update was successful. Here are the steps I followed.

    Mini help (step by step):

    -- Run psql
    sudo -u postgres psql

    -- List DB
    \l

    -- Connect to DB
    \connect nextcloud_test_db

    -- List Tables (all or by pattern)
    \dt oc_bookmarks

    -- Get info about a table
    \d oc_bookmarks

    -- Chenge column leng
    ALTER TABLE oc_bookmarks ALTER COLUMN url TYPE varchar(4000);

  10. DoM1niC commented on Apr 2, 2022

    @DoM1niC

    alter table oc_ldap_group_mapping CHANGE COLUMN 'ldap_dn' varchar(4000);

    grafik
    grafik

    Mhhh.....

  11. marcelklehr commented on Apr 2, 2022

    @marcelklehr
    Member

    Since when is 4000 a limit in Nextcloud? Where is this documented? This is a breaking change.

  12. noci2012 commented on Apr 3, 2022

    @noci2012

    Another one fir this collection...

    Updating <user_ldap> ...
    OC\DB\Exceptions\DbalException: An exception occurred while executing a query: SQLSTATE[42S22]: Column not found: 1054 Unknown column '4000' in 'where clause'
    Update failed
    Maintenance mode is kept active

  13. 4 remaining items

  14. nickvergessen commented on Apr 8, 2022

    @nickvergessen
    Member

    Forms fixed with nextcloud/forms#1149

  15. nickvergessen commented on Apr 8, 2022

    @nickvergessen
    Member

    Bookmarks opted out of oracle support: https://github.com/nextcloud/bookmarks/blob/master/appinfo/info.xml#L40-L42
    That was then fixed with #31872

  16. nickvergessen commented on Apr 8, 2022

    @nickvergessen
    Member

    "oc_external_config"."value"

    That was already fixed with #31679

    Small bug fix added in #31903 for I guess owncloud migration case

  17. nickvergessen commented on Apr 8, 2022

    @nickvergessen
    Member

    "oc_cas_ticket"."service"

    Can't find that table. What app is it from?

  18. nickvergessen commented on Apr 8, 2022

    @nickvergessen
    Member
  19. DoM1niC commented on Apr 9, 2022

    @DoM1niC

    alter table oc_ldap_group_mapping CHANGE COLUMN 'ldap_dn' varchar(4000);

    grafik grafik

    Mhhh.....

    my problems are solved now btw but THX anyway

  20. szaimen commented on Apr 25, 2022

    @szaimen
    Contributor

    Isn't this already solved in the meantime?

  21. nickvergessen commented on Apr 25, 2022

    @nickvergessen
    Member

    nextcloud/fulltextsearch#679 is still not merged...

  22. szaimen commented on Apr 25, 2022

    @szaimen
    Contributor

    right

  23. ArtificialOwl commented on Apr 25, 2022

    @ArtificialOwl
    Member

    can I get a quick review on nextcloud/fulltextsearch#679 ?

  24. szaimen commented on Apr 25, 2022

    @szaimen
    Contributor

    can I get a quick review on nextcloud/fulltextsearch#679 ?

    could you ask in the files chat? :)

  25. szaimen commented on Apr 25, 2022

    @szaimen
    Contributor

    Should be fixed with nextcloud/fulltextsearch#679

  26. added this to the Nextcloud 24 milestone on Apr 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    1. to developAccepted and waiting to be taken care ofbug

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions