Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Base version with docker compose and mariadb latest does not work anymore #1038

Closed
rchovan opened this issue Mar 19, 2020 · 7 comments
Closed

Comments

@rchovan
Copy link

rchovan commented Mar 19, 2020

Hi,
base docker compose config with mariadb latest does not work anymore. Something changed in mariadb image between versions 10.3 and 10.4. In Newest version 10.4+, 10.5+ Nextcloud can't connect to database, Last working version is 10.3.x . Tested with Adminer after installation.

connection worked with mariadb version 10.3.22

image

same settings in compose file, but can't connect to mariadb version 10.4
(on screenshot password is not filled, but it was deleted after error message)
image

docker-compose.yml

version: '2'

volumes:
  nextcloud:
  db:

services:
  db:
    image: mariadb:10.3.22
    command: --transaction-isolation=READ-COMMITTED --binlog-format=ROW --log-bin
    restart: always
    volumes:
      - /data/_docker/mariadb/db:/var/lib/mysql
    environment:
      - MYSQL_ROOT_PASSWORD=root_pwd
      - MYSQL_PASSWORD=pwd
      - MYSQL_DATABASE=nc
      - MYSQL_USER=nc
      - MYSQL_HOST=db
      - NEXTCLOUD_ADMIN_USER=admin
      - NEXTCLOUD_ADMIN_PASSWORD=supersecret

  adminer:
    links:
      - db
    image: adminer
    restart: always
    ports:
      - 8081:8080


@david883
Copy link

Same Issue here

@flower1024
Copy link

same issue

@hexdump
Copy link

hexdump commented Apr 28, 2020

Replicated, with the with-nginx-proxy/mariadb example located here. Running on Manjaro Linux with kernel Linux myhostname 5.4.35-1-MANJARO #1 SMP PREEMPT Thu Apr 23 10:54:43 UTC 2020 x86_64 GNU/Linux, Docker version 19.03.8-ce, build afacb8b7f0, and docker-compose version 1.25.5, build unknown.

Switching the version of MariaDB to 10.3.22 does appear to resolve the problem. Nextcloud successfully installed; however it showed a 504 timeout after hanging for a while during configuring admin user/initial configuration which didn't seem to affect the performance of the server (I've only just set it up, haven't performed thorough testing of the features). The 504 may be an unrelated problem.

@gandalfk7
Copy link

Hi, I was going to open a new issue but I found this digging in the older ones,
this is the same problem as the one I have:

I've encountered a problem with different docker-compose files in the examples,
the problem is that the mariadb container gets created ingoring the MYSQL_ROOT_PASSWORD parameter in the service environment and the other parameters in db.env.

Mariadb got spun up with no root password, no external access and no user and db for nextcloud.

After some digging around I found this issue: MariaDB/mariadb-docker#262 which has been quite relevant to my problem.

I can confirm that using the latest mariadb image I get the problem, the latest corresponds to the tag: 10.4.12-bionic or 10.4.12 or 10.4-bionic or 10.4.
The workardound suggested here, which suggests adding MYSQL_INITDB_SKIP_TZINFO=1 parameter, gets mariadb to behave correctly, at the expense of timezone data.

If I fix my version to 10.3.22, everything works well.

this problem seems to be shared by others:
open:
#1038
#1114
closed:
#1096
#1043

os:

Distributor ID: Debian
Description: Debian GNU/Linux 9.11 (stretch)
Release: 9.11
Codename: stretch

docker version:

Docker version 19.03.5, build 633a0ea838

docker-compose version:

docker-compose version 1.25.4, build 8d51620a
docker-py version: 4.1.0
CPython version: 3.7.5
OpenSSL version: OpenSSL 1.1.0l 10 Sep 2019

docker-compose files tested:

.examples/docker-compose/insecure/mariadb-cron-redis/fpm
.examples/docker-compose/insecure/mariadb-cron-redis/apache
.examples/docker-compose/insecure/mariadb/fpm
.examples/docker-compose/insecure/mariadb/apache

@petersjostrom
Copy link

petersjostrom commented Jan 2, 2021

I can confirm nextcloud:latest does not work with mariadb:latest as of today. (Cost me a week of re-installations etc, changed to mariadb:10.3.22 and everything works)
nextcloud:20.0.4-apache
mariadb:10.5.8+maria~focal

Edit: #514 for reference, will it solve this?

@Robert-ML
Copy link

I reached here because my Nextcloud instalation on a RaspberryPi was not working anymore. It was working 4 months ago, today it was giving me an Internal Server Error so I decided to reinstall it. Now at admin setup it was giving me "Connection refused" to the database.

I was using the latest images as of 18-Oct-2021 for Nextcloud and Mariadb (one that works on raspberry).
Nextcloud ID: sha256:22430e5ecdbe7a2592f7020dee03e2145765bfa3326ca8097e7356f10f91927d
Mariadb ID (by Yoba Systems): sha256:aef68e75c4ca4bc8693fa99718dea0f78fb022604b5d665ffc4d397d9704dd8a

Now I got Nextcloud to work again using older images (I wish I didn't delete my past working images without testing first (0_0;) ):
Nextcloud image: nextcloud:20.0.10-apache
MariaDB image: linuxserver/mariadb:110.4.20mariabionic-ls25

Hope this helps somebody.

@J0WI
Copy link
Contributor

J0WI commented Apr 4, 2023

For RaspberryPi this is a duplicate of #1589

@J0WI J0WI closed this as completed Apr 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants