Skip to content

Not enumerating databases correctly? #555

Closed

Description

@picasso566

Summary

Unraid Environment. postgressql instances and db-backup are docker images. I'm fairly certain I have something misconfigured, but there's a (small?) chance the issue is in this repo.

Installed db-backup and configured with username and password of user which has admin access to all DBs in each db instance. From the docker console I run backup-now and get this output:

/ # backup-now 2026-09-04.18:01:44 [INFO] ** [db-backup02] Starting Manual Backup for db-backup02 psql: error: connection to server at "PostgreSQL_Immich" (10.10.12.3), port 5432 failed: FATAL: database "paul" does not exist 2026-09-04.18:01:44 [INFO] ** [02-PostgreSQL_Immich__ALL] Backup 02 routines finish time: 2026-09-04 18:01:44 JST with exit code 0 2026-09-04.18:01:44 [NOTICE] ** [02-PostgreSQL_Immich__ALL] Backup 02 routines time taken: Hours: 0 Minutes: 00 Seconds: 00

I have DB01_NAME and DB02_NAME set to ALL. Am I incorrect in assuming this should enumerate all the databases instead of looking for a database with the name of the user?

The configured user is an admin of each database in each server instance. If I log in as that user in dbeaver or pgadmin for example I have full access to all databases. Perhaps the user is missing a permission which db-backup requires?

Also, it stops at this point and does not attempt to backup DB02_NAME.

Steps to reproduce

Install docker container, configure, run.

What is the expected correct behavior?

Enumerate through the databases in each db server instance (that the user has access to) and back them up.

Relevant logs and/or screenshots

Environment

  • Method of Usage (Container/ Bare metal) Docker
  • OS: UnRaid
  • DB-Backup Version (dbb version): 4.1.100
  • Container Image version / tag (image_version from inside container): tiredofit/db-backup:latest
Any logs | compose.yml

postgres 16 and 17

Resultant docker create from the unRaid config is as follows:

docker create --name='db-backup' --net='br0' --pids-limit 2048 -e TZ="Asia/Tokyo" -e HOST_OS="Unraid" -e HOST_HOSTNAME="Hosty" -e HOST_CONTAINERNAME="db-backup" -e 'TCP_PORT_9876'='9876' -e 'DB01_NAME'='ALL' -e 'DB01_TYPE'='pgsql' -e 'DB01_HOST'='postgresql17' -e 'DB01_USER'='paul' -e 'DB01_PASS'='xxx' -e 'DB01_PORT'='5432' -e 'DB02_NAME'='ALL' -e 'DB02_TYPE'='pgsql' -e 'DB02_HOST'='PostgreSQL_Immich' -e 'DB02_USER'='paul' -e 'DB02_PASS'='xxx' -e 'DB01_PORT'='5433' -e 'DEFAULT_SPLIT_DB'='TRUE' -e 'DEFAULT_BACKUP_INTERVAL'='1440' -e 'DEFAULT_BACKUP_BEGIN'='0300' -e 'DEFAULT_CLEANUP_TIME'='10080' -e 'DEFAULT_COMPRESSION'='ZSTD' -e 'DEFAULT_COMPRESSION_LEVEL'='3' -e 'DEFAULT_GZ_RSYNCABLE'='FALSE' -e 'DEBUG_MODE'='FALSE' -e 'CONTAINER_ENABLE_MONITORING'='FALSE' -e 'DEFAULT_CHECKSUM'='NONE' -e 'DEFAULT_CREATE_LATEST_SYMLINK'='FALSE' -e 'DEFAULT_ENABLE_PARALLEL_COMPRESSION'='autodetected' -e 'USER_DBBACKUP'='99' -e 'GROUP_DBBACKUP'='100' -e 'DEFAULT_FILESYSTEM_PATH_PERMISSION'='755' -e 'DEFAULT_FILESYSTEM_PERMISSION'='777' -l net.unraid.docker.managed=dockerman -l net.unraid.docker.icon='https://raw.githubusercontent.com/A75G/docker-templates/master/templates/icons/db-backup.png' -v '/mnt/user/RustDirect/db-backup/':'/backup':'rw' 'tiredofit/db-backup:latest'

Possible fixes

Activity

  1. tiredofit commented on Sep 4, 2026

    @tiredofit
    Collaborator

    Hi - 4.1.100 is an older unsupported version, yet you were likely missing the authentication database environment variable for Postgres ALL backups DB01_AUTH=... The documentation to support for 4.x series is here: https://github.com/nfrastack/db-backup/blob/4/README.md

  2. locked and limited conversation to collaborators on Sep 4, 2026
  3. converted this issue into a discussion #558 on Sep 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions