Docker Nextcloud DB is not startig anymore

Support intro

Sorry to hear you’re facing problems :slightly_frowning_face:

help.nextcloud.com is for home/non-enterprise users. If you’re running a business, paid support can be accessed via portal.nextcloud.com where we can ensure your business keeps running smoothly.

In order to help you as quickly as possible, before clicking Create Topic please provide as much of the below as you can. Feel free to use a pastebin service for logs, otherwise either indent short log examples with four spaces:

example

Or for longer, use three backticks above and below the code snippet:

longer
example
here

Some or all of the below information will be requested if it isn’t supplied; for fastest response please provide as much as you can :heart:

Nextcloud version (eg, 20.0.5): 24.0.0
Operating system and version (eg, Ubuntu 20.04): docker
Apache or nginx version (eg, Apache 2.4.25): apache
PHP version (eg, 7.4): default

The issue you are facing: Database not Coming up

Is this the first time you’ve seen this error? (Y/N): Y

Steps to replicate it:

  1. Wanted to update from 24 to 24.0.2 using docker-compose pull && docker-compose up
  2. It failed (database not coming up)
  3. i revertet the whole system with all its docker and “data” data to the state i stopped the containers
  4. i run docker-compose start (to not update any containers)
  5. database is not coming up

Output of the Nextcloud Container:

nextcloud-db_1  | 2022-06-30 18:22:04+00:00 [Note] [Entrypoint]: Entrypoint script for MariaDB Server 1:10.8.3+maria~jammy started.
nextcloud-db_1  | 2022-06-30 18:22:04+00:00 [Note] [Entrypoint]: Switching to dedicated user 'mysql'
nextcloud-db_1  | 2022-06-30 18:22:04+00:00 [Note] [Entrypoint]: Entrypoint script for MariaDB Server 1:10.8.3+maria~jammy started.
nextcloud-db_1  | 2022-06-30 18:22:05+00:00 [Note] [Entrypoint]: MariaDB upgrade information missing, assuming required
nextcloud-db_1  | 2022-06-30 18:22:05+00:00 [Note] [Entrypoint]: MariaDB upgrade (mariadb-upgrade) required, but skipped due to $MARIADB_AUTO_UPGRADE setting
nextcloud-db_1  | 2022-06-30 18:22:05 0 [Note] mariadbd (server 10.8.3-MariaDB-1:10.8.3+maria~jammy) starting as process 1 ...
nextcloud-db_1  | 2022-06-30 18:22:05 0 [Warning] You need to use --log-bin to make --binlog-format work.
nextcloud-db_1  | 2022-06-30 18:22:05 0 [Note] InnoDB: Compressed tables use zlib 1.2.11
nextcloud-db_1  | 2022-06-30 18:22:05 0 [Note] InnoDB: Number of transaction pools: 1
nextcloud-db_1  | 2022-06-30 18:22:05 0 [Note] InnoDB: Using generic crc32 instructions
nextcloud-db_1  | 2022-06-30 18:22:05 0 [Warning] mariadbd: io_uring_queue_init() failed with ENOSYS: check seccomp filters, and the kernel version (newer than 5.1 required)
nextcloud-db_1  | 2022-06-30 18:22:05 0 [Warning] InnoDB: liburing disabled: falling back to innodb_use_native_aio=OFF
nextcloud-db_1  | 2022-06-30 18:22:05 0 [Note] InnoDB: Initializing buffer pool, total size = 128.000MiB, chunk size = 2.000MiB
nextcloud-db_1  | 2022-06-30 18:22:05 0 [Note] InnoDB: Completed initialization of buffer pool
nextcloud-db_1  | 2022-06-30 18:22:06 0 [ERROR] InnoDB: Upgrade after a crash is not supported. The redo log was created with MariaDB 10.6.5.
nextcloud-db_1  | 2022-06-30 18:22:06 0 [ERROR] InnoDB: Plugin initialization aborted with error Generic error
nextcloud-db_1  | 2022-06-30 18:22:06 0 [Note] InnoDB: Starting shutdown...
nextcloud-db_1  | 2022-06-30 18:22:06 0 [ERROR] Plugin 'InnoDB' init function returned error.
nextcloud-db_1  | 2022-06-30 18:22:06 0 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
nextcloud-db_1  | 2022-06-30 18:22:06 0 [Note] Plugin 'FEEDBACK' is disabled.
nextcloud-db_1  | 2022-06-30 18:22:06 0 [ERROR] Unknown/unsupported storage engine: InnoDB
nextcloud-db_1  | 2022-06-30 18:22:06 0 [ERROR] Aborting
nextcloud-db_1  | 2022-06-30 18:23:08+00:00 [Note] [Entrypoint]: Entrypoint script for MariaDB Server 1:10.8.3+maria~jammy started.
nextcloud-db_1  | 2022-06-30 18:23:09+00:00 [Note] [Entrypoint]: Switching to dedicated user 'mysql'
nextcloud-db_1  | 2022-06-30 18:23:09+00:00 [Note] [Entrypoint]: Entrypoint script for MariaDB Server 1:10.8.3+maria~jammy started.
nextcloud-db_1  | 2022-06-30 18:23:09+00:00 [Note] [Entrypoint]: MariaDB upgrade information missing, assuming required
nextcloud-db_1  | 2022-06-30 18:23:09+00:00 [Note] [Entrypoint]: MariaDB upgrade (mariadb-upgrade) required, but skipped due to $MARIADB_AUTO_UPGRADE setting
nextcloud-db_1  | 2022-06-30 18:23:09 0 [Note] mariadbd (server 10.8.3-MariaDB-1:10.8.3+maria~jammy) starting as process 1 ...
nextcloud-db_1  | 2022-06-30 18:23:09 0 [Warning] You need to use --log-bin to make --binlog-format work.
nextcloud-db_1  | 2022-06-30 18:23:09 0 [Note] InnoDB: Compressed tables use zlib 1.2.11
nextcloud-db_1  | 2022-06-30 18:23:09 0 [Note] InnoDB: Number of transaction pools: 1
nextcloud-db_1  | 2022-06-30 18:23:09 0 [Note] InnoDB: Using generic crc32 instructions
nextcloud-db_1  | 2022-06-30 18:23:09 0 [Warning] mariadbd: io_uring_queue_init() failed with ENOSYS: check seccomp filters, and the kernel version (newer than 5.1 required)
nextcloud-db_1  | 2022-06-30 18:23:09 0 [Warning] InnoDB: liburing disabled: falling back to innodb_use_native_aio=OFF
nextcloud-db_1  | 2022-06-30 18:23:09 0 [Note] InnoDB: Initializing buffer pool, total size = 128.000MiB, chunk size = 2.000MiB
nextcloud-db_1  | 2022-06-30 18:23:09 0 [Note] InnoDB: Completed initialization of buffer pool
nextcloud-db_1  | 2022-06-30 18:23:09 0 [ERROR] InnoDB: Upgrade after a crash is not supported. The redo log was created with MariaDB 10.6.5.
nextcloud-db_1  | 2022-06-30 18:23:09 0 [ERROR] InnoDB: Plugin initialization aborted with error Generic error
nextcloud-db_1  | 2022-06-30 18:23:09 0 [Note] InnoDB: Starting shutdown...
nextcloud-db_1  | 2022-06-30 18:23:10 0 [ERROR] Plugin 'InnoDB' init function returned error.
nextcloud-db_1  | 2022-06-30 18:23:10 0 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
nextcloud-db_1  | 2022-06-30 18:23:10 0 [Note] Plugin 'FEEDBACK' is disabled.
nextcloud-db_1  | 2022-06-30 18:23:10 0 [ERROR] Unknown/unsupported storage engine: InnoDB
nextcloud-db_1  | 2022-06-30 18:23:10 0 [ERROR] Aborting

I don’t understand how this cannot work, since everything should be exactly in the state it was when it was still running.

This is saying that it can’t process an upgrade on the DB when it isn’t in a clean shutdown state.

Maybe you can change your MariaDB image tag to mariadb:10.6.5, let it start and process the redo log and then gracefully stop, then change it back to mariadb:latest or whatever you have currently.

did you happen to upgrade to MariaDb 10.8? e.g. if you use :latest docker tag

this version is at least not supported by Nextcloud

https://docs.nextcloud.com/server/stable/admin_manual/installation/system_requirements.html

image

from what I see in the DB log they might have changed storage engine which causes you database files to become incompatible with the binaries

@KarlF12 and @wwe
Thanks a million! I was using the official dockerfile from dockerhub and there is stupidly no version pinned! (i created an issue on that)

I got it running again, very unfortunately i do not understand why/how.

i rolled back the snapshot several times before it was working, and i also tried to get the database to a supported version without luck.

in the end i rolled back, set the database to 10.7.4 then i “docker-compose up” and after a walk it somehow was running.
In the logs i could only find some entries about oc_polls which i do not care about

nextcloud-db_1  | 2022-07-07 18:43:34 0 [Note] InnoDB: Recovered page [page id: space=1669, page number=2] to './nextcloud/oc_polls_options.ibd' from the doublewrite

but it is possible that wasnt looking till the very start of the container - since i was only cheking it the next morning…

my plan is to let it pinned there until some day nextcloud does support 10.7.
also i saw the stable tag and when 24 becomes stable i will switch to it as well…

thanks a lot for pointing me to the right direction!

1 Like