u/SpHoneybadger

Docker: Nextcloud error while trying to create admin account
▲ 4 r/UgreenNASync+1 crossposts

Docker: Nextcloud error while trying to create admin account

Noob following a guide on setting up Nextcloud on my DH4300 Plus through the NAS docker UI: https://www.youtube.com/watch?v=IJ1LWRNfBKM . I noted that there were some things I had to change on the .yaml. I had to create a separate .env file for the creds and the NAS IP (won't post those for obvious reasons lol).

https://preview.redd.it/cg3b3on6x61h1.png?width=568&format=png&auto=webp&s=5930094fd28b0db413509d213706ec8db7e413bb

.yaml:

services:
  db:
    image: mariadb:10.11
    container_name: nextcloud_db
    restart: unless-stopped
    command: --transaction-isolation=READ-COMMITTED --binlog-format=ROW
    networks:
      - nextcloud-net
    volumes:
      - /volume1/docker/nextcloud/db:/var/lib/mysql
    environment:
      - MYSQL_ROOT_PASSWORD=${MYSQL_ROOT_PASSWORD}
      - MYSQL_DATABASE=nextcloud
      - MYSQL_USER=nextcloud
      - MYSQL_PASSWORD=${MYSQL_PASSWORD}

  redis:
    image: redis:alpine
    container_name: nextcloud_redis
    restart: unless-stopped
    networks:
      - nextcloud-net
    command: ["redis-server", "--requirepass", "${REDIS_PASSWORD}", "--appendonly", "yes"]
    volumes:
      - /volume1/docker/nextcloud/redis:/data

  app:
    image: nextcloud:latest
    container_name: nextcloud_app
    restart: unless-stopped
    networks:
      - nextcloud-net
    ports:
      - 8080:80
    volumes:
      - /volume1/docker/nextcloud/html:/var/www/html
      - /volume1/docker/nextcloud/data:/var/www/html/data
      - /volume1/docker/nextcloud/config:/var/www/html/config
      - /volume1/docker/nextcloud/custom_apps:/var/www/html/custom_apps
      - /volume1/docker/nextcloud/themes:/var/www/html/themes
      - /etc/timezone:/etc/timezone:ro
      - /etc/localtime:/etc/localtime:ro
    environment:
      - PUID=1000
      - PGID=100
      - TZ=${TIMEZONE}
      - NEXTCLOUD_TRUSTED_DOMAINS=${NAS_IP_OR_DOMAIN}
      - NEXTCLOUD_DB_TYPE=mysql
      - MYSQL_HOST=db
      - MYSQL_DATABASE=nextcloud
      - MYSQL_USER=nextcloud
      - MYSQL_PASSWORD=${MYSQL_PASSWORD}
      - NEXTCLOUD_ADMIN_USER=${NEXTCLOUD_ADMIN_USER}
      - NEXTCLOUD_ADMIN_PASSWORD=${NEXTCLOUD_ADMIN_PASSWORD}
      - REDIS_HOST=redis
      - REDIS_HOST_PASSWORD=${REDIS_PASSWORD}
    depends_on:
      - db
      - redis

  cron:
    image: nextcloud:latest
    container_name: nextcloud_cron
    restart: unless-stopped
    networks:
      - nextcloud-net
    volumes:
      - /volume1/docker/nextcloud/html:/var/www/html
      - /volume1/docker/nextcloud/data:/var/www/html/data
      - /volume1/docker/nextcloud/config:/var/www/html/config
      - /volume1/docker/nextcloud/custom_apps:/var/www/html/custom_apps
    entrypoint: /cron.sh
    depends_on:
      - app

networks:
  nextcloud-net:
    driver: bridge

However, I keep getting an error when I try and create my admin account:

Error while trying to create admin account: An exception occurred in the driver: SQLSTATE[HY000] [2002] Connection refused

...only further info I can find is on nextcloud_db:

026-05-14 23:22:47+00:00 [Note] [Entrypoint]: Entrypoint script for MariaDB Server 1:10.11.16+maria~ubu2204 started.
2026-05-14 23:22:49+00:00 [Warn] [Entrypoint]: /sys/fs/cgroup///memory.pressure not writable, functionality unavailable to MariaDB
2026-05-14 23:22:49+00:00 [Note] [Entrypoint]: Switching to dedicated user 'mysql'
2026-05-14 23:22:49+00:00 [Note] [Entrypoint]: Entrypoint script for MariaDB Server 1:10.11.16+maria~ubu2204 started.
2026-05-14 23:22:50+00:00 [Note] [Entrypoint]: Initializing database files
2026-05-14 23:23:05 0 [Warning] mariadbd: io_uring_queue_init() failed with EPERM: sysctl kernel.io_uring_disabled has the value 2, or 1 and the user of the process is not a member of sysctl kernel.io_uring_group. (see man 2 io_uring_setup).
create_uring failed: falling back to libaio

What gives?

reddit.com
u/SpHoneybadger — 7 days ago