Steps to reproduce
- Following this guide using linked sample docker-compose.yml and updating local .env vars
- Running `docker-compose up -d’ starts the containers but owncloud/server is unhealthy
- looking at docker logs it shows server waiting for mysql but mysql container keeps showing entry script errors
Expected behaviour
docker-compose should start containers and owncloud server should connect to mysql container
Actual behaviour
docker-compose starts mysql and reddis containers successfully but owncloud server container in unhealthy. maridb/mysql container Logs below:
2021-12-20 18:15:35+00:00 [Note] [Entrypoint]: Entrypoint script for MariaDB Server 1:10.5.13+maria~focal started.,
2021-12-20 18:15:36+00:00 [ERROR] [Entrypoint]: mysqld failed while attempting to check config,
command was: mysqld --max-allowed-packet=128M --innodb-log-file-size=64M --verbose --help --log-bin-index=/tmp/tmp.OPseRkbMvE,
owncloud conatiner logs:
Creating volume folders...,
Creating hook folders...,
Waiting for MySQL...
reddis container logs:
1:C 20 Dec 2021 18:51:34.634 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo,
1:C 20 Dec 2021 18:51:34.635 # Redis version=6.2.6, bits=64, commit=00000000, modified=0, pid=1, just started,
1:C 20 Dec 2021 18:51:34.635 # Configuration loaded,
1:M 20 Dec 2021 18:51:34.638 * monotonic clock: POSIX clock_gettime,
1:M 20 Dec 2021 18:51:34.641 * Running mode=standalone, port=6379.,
1:M 20 Dec 2021 18:51:34.641 # WARNING: The TCP backlog setting of 511 cannot be enforced because /proc/sys/net/core/somaxconn is set to the lower value of 128.,
1:M 20 Dec 2021 18:51:34.641 # Server initialized,
1:M 20 Dec 2021 18:51:34.641 # WARNING overcommit_memory is set to 0! Background save may fail under low memory condition. To fix this issue add 'vm.overcommit_memory = 1' to /etc/sysctl.conf and then reboot or run the command 'sysctl vm.overcommit_memory=1' for this to take effect.,
1:M 20 Dec 2021 18:51:34.642 * Loading RDB produced by version 6.2.6,
1:M 20 Dec 2021 18:51:34.642 * RDB age 835 seconds,
1:M 20 Dec 2021 18:51:34.642 * RDB memory usage when created 0.79 Mb,
1:M 20 Dec 2021 18:51:34.642 # Done loading RDB, keys loaded: 0, keys expired: 0.,
1:M 20 Dec 2021 18:51:34.642 * DB loaded from disk: 0.000 seconds,
1:M 20 Dec 2021 18:51:34.642 * Ready to accept connections,
1:signal-handler (1640026343) Received SIGTERM scheduling shutdown...,
1:M 20 Dec 2021 18:52:23.521 # User requested shutdown...,
1:M 20 Dec 2021 18:52:23.521 * Saving the final RDB snapshot before exiting.,
1:M 20 Dec 2021 18:52:23.583 * DB saved on disk,
1:M 20 Dec 2021 18:52:23.583 # Redis is now ready to exit, bye bye...
The demo oc-eval container worked fine when I ran this command:
ocker run --rm --name oc-eval -d -e OWNCLOUD_DOMAIN=localhost:8080 -p8080:8080 owncloud/server
Server configuration
Operating system:
odroid c2 hardware with ubuntu 20.04 image odroid-c2:odroid-c2 [ODROID Wiki]
cat /etc/os-release
NAME=“Ubuntu”
VERSION=“20.04.3 LTS (Focal Fossa)”
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME=“Ubuntu 20.04.3 LTS”
VERSION_ID=“20.04”
VERSION_CODENAME=focal
UBUNTU_CODENAME=focal
uname -r
Linux odroid 3.16.85-65 #1 SMP PREEMPT Mon Jan 18 13:32:38 UTC 2021 aarch64 aarch64 aarch64 GNU/Linux
version: "3"
volumes:
files:
driver: local
mysql:
driver: local
redis:
driver: local
services:
owncloud:
image: owncloud/server:${OWNCLOUD_VERSION}
container_name: owncloud_server
restart: always
ports:
- ${HTTP_PORT}:8080
depends_on:
- mariadb
- redis
environment:
- OWNCLOUD_DOMAIN=${OWNCLOUD_DOMAIN}
- OWNCLOUD_DB_TYPE=mysql
- OWNCLOUD_DB_NAME=owncloud
- OWNCLOUD_DB_USERNAME=owncloud
- OWNCLOUD_DB_PASSWORD=owncloud
- OWNCLOUD_DB_HOST=mariadb
- OWNCLOUD_ADMIN_USERNAME=${ADMIN_USERNAME}
- OWNCLOUD_ADMIN_PASSWORD=${ADMIN_PASSWORD}
- OWNCLOUD_MYSQL_UTF8MB4=true
- OWNCLOUD_REDIS_ENABLED=true
- OWNCLOUD_REDIS_HOST=redis
- OWNCLOUD_LOGLEVEL=0
healthcheck:
test: ["CMD", "/usr/bin/healthcheck"]
interval: 30s
timeout: 10s
retries: 5
volumes:
- files:/mnt/data
mariadb:
image: mariadb:10.5
container_name: owncloud_mariadb
restart: always
environment:
- MYSQL_ROOT_PASSWORD=owncloud
- MYSQL_USER=owncloud
- MYSQL_PASSWORD=owncloud
- MYSQL_DATABASE=owncloud
command: ["--max-allowed-packet=128M", "--innodb-log-file-size=64M"]
healthcheck:
test: ["CMD", "mysqladmin", "ping", "-u", "root", "--password=owncloud"]
interval: 10s
timeout: 5s
retries: 5
volumes:
- mysql:/var/lib/mysql
redis:
image: redis:6
container_name: owncloud_redis
restart: always
command: ["--databases", "1"]
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 10s
timeout: 5s
retries: 5
volumes:
- redis:/data