The Basics
- Nextcloud Server version (e.g., 29.x.x):
30.0.4snap1
- Operating system and version (e.g., Ubuntu 24.04):
Ubuntu 22.04.5 LTS x86_64
- Web server and version (e.g, Apache 2.4.25):
Apache 2.4.25-1
- Reverse proxy and version _(e.g. nginx 1.27.2)
NginX Proxy Manager v2.12.1 running as a docker container
- PHP version (e.g, 8.3):
8.1
- Is this the first time you’ve seen this error? (Yes / No):
yes
- When did this problem seem to first start?
2 days ago on 12/18/24
- Installation method (e.g. AlO, NCP, Bare Metal/Archive, etc.)
snap and baremetal(?)
- Are you using CloudfIare, mod_security, or similar? (Yes / No)
not that i know of
Summary of the issue you are facing:
When I was trying to get some documents to sync between my computer and my phone I realized that this wasn’t working, and that when I looked at my nextcloud desktop client it said that both my accounts were offline and not syncing currently. I then looked at my management panel and it said that nextcloud was down. finally I thought oh I must just need to restart it so I ssh’d and ran the command “snap restart nextcloud” then when I looked back at the web address, I found that I was put into maintenance mode. At first maybe I thought I was interrupting an update, but I have a cronjob that does that at 3am every day so I don’t think it was that.
Steps to replicate it (hint: details matter!):
- restart nextcloud with “snap restart nextcloud”
Log entries
Nextcloud
Please provide the log entries from your Nextcloud log that are generated during the time of problem (via the Copy raw option from Administration settings->Logging screen or from your nextcloud.log
located in your data directory). Feel free to use a pastebin/gist service if necessary.
Exception: Database error when running migration 0009Date20240116000000 for app duplicatefinder An exception occurred while executing a query: SQLSTATE[42000]: Syntax error or access violation: 1071 Specified key was too long; max key length is 3072 bytes
Detailed logs
Preparing update
Set log level to debug
Turned on maintenance mode
Repair step: Repair MySQL collation
Repair info: All tables already have the correct collation -> nothing to do
Repair step: Copy data from accounts table when migrating from ownCloud
Repair step: Drop account terms table when migrating from ownCloud
Updating database schema
Updated database
Exception: Database error when running migration 0009Date20240116000000 for app duplicatefinder An exception occurred while executing a query: SQLSTATE[42000]: Syntax error or access violation: 1071 Specified key was too long; max key length is 3072 bytes
Web Browser
If the problem is related to the Web interface, open your browser inspector Console and Network tabs while refreshing (reloading) and reproducing the problem. Provide any relevant output/errors here that appear.
PASTE
Web server / Reverse Proxy
The output of your Apache/nginx/system log in /var/log/____
:
PASTE HERE
Configuration
Nextcloud
The output of occ config:list system
or similar is best, but, if not possible, the contents of your config.php
file from /path/to/nextcloud
is fine (make sure to remove any identifiable information!):
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": {
"apps_paths": [
{
"path": "\/snap\/nextcloud\/current\/htdocs\/apps",
"url": "\/apps",
"writable": false
},
{
"path": "\/var\/snap\/nextcloud\/current\/nextcloud\/extra-apps",
"url": "\/extra-apps",
"writable": true
}
],
"supportedDatabases": [
"mysql"
],
"memcache.locking": "\\OC\\Memcache\\Redis",
"memcache.local": "\\OC\\Memcache\\Redis",
"redis": {
"host": "***REMOVED SENSITIVE VALUE***",
"port": 0
},
"log_type": "file",
"logfile": "\/var\/snap\/nextcloud\/current\/logs\/nextcloud.log",
"logfilemode": 416,
"instanceid": "***REMOVED SENSITIVE VALUE***",
"passwordsalt": "***REMOVED SENSITIVE VALUE***",
"secret": "***REMOVED SENSITIVE VALUE***",
"datadirectory": "***REMOVED SENSITIVE VALUE***",
"dbtype": "mysql",
"version": "30.0.4.1",
"overwrite.cli.url": "https:\/\/nextcloud.pokeypen7.us",
"versions_retention_obligation": "120, 240",
"overwriteprotocol": "https",
"dbname": "***REMOVED SENSITIVE VALUE***",
"dbhost": "***REMOVED SENSITIVE VALUE***",
"dbport": "",
"dbtableprefix": "oc_",
"mysql.utf8mb4": true,
"dbuser": "***REMOVED SENSITIVE VALUE***",
"dbpassword": "***REMOVED SENSITIVE VALUE***",
"installed": true,
"maintenance": false,
"trusted_domains": [
"nextcloud.pokeypen7.us",
"mcserver",
"192.168.68.140",
"***REMOVED SENSITIVE VALUE***"
],
"trusted_proxies": "***REMOVED SENSITIVE VALUE***",
"twofactor_enforced": "false",
"twofactor_enforced_groups": [
"admin"
],
"twofactor_enforced_excluded_groups": [],
"default_phone_region": "US",
"loglevel": 2,
"mail_smtpmode": "smtp",
"mail_smtpsecure": "ssl",
"mail_sendmailmode": "smtp",
"mail_from_address": "***REMOVED SENSITIVE VALUE***",
"mail_domain": "***REMOVED SENSITIVE VALUE***",
"mail_smtpauth": 1,
"mail_smtphost": "***REMOVED SENSITIVE VALUE***",
"mail_smtpport": "465",
"mail_smtpname": "***REMOVED SENSITIVE VALUE***",
"mail_smtppassword": "***REMOVED SENSITIVE VALUE***",
"maintenance_window_start": 1,
"app_install_overwrite": [
"news"
],
"theme": ""
}
}
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:
- activity: 3.0.0
- admin_audit: 1.20.0
- app_api: 4.0.3
- bruteforcesettings: 3.0.0
- cfg_share_links: 6.1.1
- checksum: 1.2.5
- circles: 30.0.0
- cloud_federation_api: 1.13.0
- comments: 1.20.1
- contactsinteraction: 1.11.0
- dashboard: 7.10.0
- dav: 1.31.1
- drawio: 3.0.3
- duplicatefinder: 1.2.6
- federatedfilesharing: 1.20.0
- federation: 1.20.0
- files: 2.2.0
- files_accesscontrol: 1.20.1
- files_downloadlimit: 3.0.0
- files_pdfviewer: 3.0.0
- files_reminders: 1.3.0
- files_sharing: 1.22.0
- files_trashbin: 1.20.1
- files_versions: 1.23.0
- files_zip: 2.1.0
- fileslibreofficeedit: 2.0.1
- firstrunwizard: 3.0.0
- fulltextsearch: 30.0.0
- fulltextsearch_elasticsearch: 30.0.0
- impersonate: 1.17.0
- integration_google: 3.1.0
- login_notes: 1.6.1
- logreader: 3.0.0
- lookup_server_connector: 1.18.0
- mail: 4.1.0
- metadata: 0.21.0
- news: 25.1.1
- nextcloud_announcements: 2.0.0
- notes: 4.11.0
- notifications: 3.0.0
- oauth2: 1.18.1
- password_policy: 2.0.0
- photos: 3.0.2
- privacy: 2.0.0
- provisioning_api: 1.20.0
- qownnotesapi: 24.11.0
- recommendations: 3.0.0
- registration: 2.5.0
- related_resources: 1.5.0
- richdocuments: 8.5.3
- richdocumentscode: 24.4.1002
- serverinfo: 2.0.0
- settings: 1.13.0
- sharebymail: 1.20.0
- support: 2.0.0
- survey_client: 2.0.0
- suspicious_login: 8.0.0
- systemtags: 1.20.0
- text: 4.1.0
- theming: 2.5.0
- thesearchpage: 1.2.8
- twofactor_backupcodes: 1.19.0
- twofactor_totp: 12.0.0-dev
- user_status: 1.10.0
- viewer: 3.0.0
- weather_status: 1.10.0
- webhook_listeners: 1.1.0-dev
- workflowengine: 2.12.0
Disabled: - encryption: 2.18.0
- files_archive: 1.2.3 (installed 1.2.3)
- files_external: 1.22.0
- files_rightclick: 0.15.1 (installed 1.6.0)
- twofactor_nextcloud_notification: 4.0.0
- twofactor_reminder: 1.1.0 (installed 1.1.0)
- user_ldap: 1.21.0
Tips for increasing the likelihood of a response
- Use the
preformatted text
formatting option in the editor for all log entries and configuration output. - If screenshots are useful, feel free to include them.
- If possible, also include key error output in text form so it can be searched for.
- Try to edit log output only minimally (if at all) so that it can be ran through analyzers / formatters by those trying to help you.