Cannot connect to database, "Database 'Username' does not exist"


We have two QNAP Nas running different PostgresSQL instances I created a Backup Job on one of the NAS and everything is working very well, but when I tried to create a similar backup job for the second NAS, I could not get SQLBackupAndFTP to connect to the database. When I press on Test Connection, the Error I get is test failed. psql: FATAL: database “postgres” does not exist.

FYI the database is called test_nas, username and password is postgres.
I am pretty sure that SQLBackup can make a connection to the database, because if I put in a wrong password I get an authentification error but it seems to me that it does not find the database because it is not called “postgres”.

Is there a way how I can pass the real name of the db somehow on the connection level?

The client and server are on the same network and we do not block any ports on the NAS.

Thank you very much for your input. I appreceate it a lot.

Hi Lukas_Eggenschwiler,

During the test connection, SQLBackupAndFTP tries to connect to “postgres” database, because it is a system database and we expect that it exists.

Do we understand correctly that the “postgres” database doesn’t exist on your side?


Thanks for your reply. In the php_PgAdmin I do not see a “postgres” database so therefore I would asume that there is no such db. Is this a wrong postgres configuration?


Hi Lukas_Eggenschwiler,

According to the following recommendations postgres is the default database and PostgreSQL Server can work without it in theory. In the documentation we sent says:

“The database server itself does not require the postgres database to exist, but many external utility programs assume it exists.”

We are one of such application. Could you please try to create that database and check if it resolves the issue.

Sorry for the inconvenience.

I did create the postgres db and now everything seems to work. Thank you for your hint.

Hi Lukas_Eggenschwiler,

That’s great! Thank you for your reply.

Please feel free to contact us on any issues or concerns.