From: Erik Wienhold <ewie@ewie.name>
To: Matthias Apitz <guru@unixarea.de>
To: Postgres General <pgsql-general@postgresql.org>
Subject: Re: database postgres not found
Date: Wed, 1 Feb 2023 12:54:18 +0100 (CET)
Message-ID: <866848204.104800.1675252458428@office.mailbox.org> (raw)
In-Reply-To: <20230201103319.GA9@sh4-5.1blu.de>
References: <20230201103319.GA9@sh4-5.1blu.de>
> On 01/02/2023 11:33 CET Matthias Apitz <guru@unixarea.de> wrote:
>
> Hello,
>
> I've a problem with a PostgreSQL 12.x server not setup or managed by me. that
> the database 'postgres' is not found:
>
> $ psql -Upostgres postgres
> psql: error: ERROR: no such database: postgres
>
> but the database is there as a SELECT shows:
>
> $ psql -Upostgres lbs_lbsoclc01_dev_r1
> psql (12.11)
> Type "help" for help.
>
> lbs_lbsoclc01_dev_r1=# select * from pg_database where datname = 'postgres' ;
> oid | datname | datdba | encoding | datcollate | datctype | datistemplate | datallowconn | datconnlimit | datlastsysoid | datfrozenxid | datminmxid | dattablespace | datacl
> -------+----------+--------+----------+-------------+-------------+---------------+--------------+--------------+---------------+--------------+------------+---------------+--------
> 14344 | postgres | 10 | 6 | en_US.UTF-8 | en_US.UTF-8 | f | t | -1 | 14343 | 479 | 1 | 1663 |
> (1 row)
>
> What does this mean?
Error message "no such database: postgres" is not from Postgres but likely from
PgBouncer. This means the database is not configured in PgBouncer for clients
to connect to.
--
Erik
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-general@postgresql.org
Cc: ewie@ewie.name, guru@unixarea.de
Subject: Re: database postgres not found
In-Reply-To: <866848204.104800.1675252458428@office.mailbox.org>
References: <20230201103319.GA9@sh4-5.1blu.de> <866848204.104800.1675252458428@office.mailbox.org>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox