public inbox for [email protected]
help / color / mirror / Atom feedFrom: Konstantin Knizhnik <[email protected]>
To: Jaime Casanova <[email protected]>
Cc: Li Japin <[email protected]>
Cc: [email protected] <[email protected]>
Subject: Re: Built-in connection pooler
Date: Sun, 5 Jul 2020 16:46:09 +0300
Message-ID: <[email protected]> (raw)
In-Reply-To: <CAJGNTePSpVRMApCq50-veJGtPcMBPDLio1NkwkNE3wnDsX0KwQ@mail.gmail.com>
References: <[email protected]>
<[email protected]>
<[email protected]>
<CAN-V+g8h5HFQj_Y7HzFvcuCzOL=F8VDadNxCwQ8exkKOYB8KJA@mail.gmail.com>
<[email protected]>
<CAN-V+g--21y8=GhWFoTGqU0UKxSgp0ZFKAMZM2KbcDjey-Ty8w@mail.gmail.com>
<[email protected]>
<CAN-V+g99RvCr5GCRkn_H6k2Mom76HcAqFrfzQxuFNEa-Hip5Mw@mail.gmail.com>
<[email protected]>
<CAN-V+g9gTUhR_cxBr2yjc3MMbpk+kopwbbiHB6kRe2whfjFYnQ@mail.gmail.com>
<[email protected]>
<[email protected]>
<[email protected]>
<KL1PR0601MB380006383DE897E2026ACEC6B6D40@KL1PR0601MB3800.apcprd06.prod.outlook.com>
<[email protected]>
<CAJGNTePSpVRMApCq50-veJGtPcMBPDLio1NkwkNE3wnDsX0KwQ@mail.gmail.com>
Thank your for your help.
On 05.07.2020 07:17, Jaime Casanova wrote:
> You should also allow cursors without the WITH HOLD option or there is
> something i'm missing?
Yes, good point.
> a few questions about tainted backends:
> - why the use of check_primary_key() and check_foreign_key() in
> contrib/spi/refint.c make the backend tainted?
I think this is because without it contrib test is not passed with
connection pooler.
This extension uses static variables which are assumed to be session
specific but in case f connection pooler are shared by all backends.
> - the comment in src/backend/commands/sequence.c needs some fixes, it
> seems just quickly typed
Sorry, done.
>
> some usability problem:
> - i compiled this on a debian machine with "--enable-debug
> --enable-cassert --with-pgport=54313", so nothing fancy
> - then make, make install, and initdb: so far so good
>
> configuration:
> listen_addresses = '*'
> connection_proxies = 20
>
> and i got this:
>
> """
> jcasanov@DangerBox:/opt/var/pgdg/14dev$ /opt/var/pgdg/14dev/bin/psql
> -h 127.0.0.1 -p 6543 postgres
> psql: error: could not connect to server: no se pudo conectar con el
> servidor: No existe el fichero o el directorio
> ¿Está el servidor en ejecución localmente y aceptando
> conexiones en el socket de dominio Unix «/var/run/postgresql/.s.PGSQL.54313»?
> """
>
> but connect at the postgres port works well
> """
> jcasanov@DangerBox:/opt/var/pgdg/14dev$ /opt/var/pgdg/14dev/bin/psql
> -h 127.0.0.1 -p 54313 postgres
> psql (14devel)
> Type "help" for help.
>
> postgres=# \q
> jcasanov@DangerBox:/opt/var/pgdg/14dev$ /opt/var/pgdg/14dev/bin/psql
> -p 54313 postgres
> psql (14devel)
> Type "help" for help.
>
> postgres=#
> """
>
> PS: unix_socket_directories is setted at /tmp and because i'm not
> doing this with postgres user i can use /var/run/postgresql
>
Looks like for some reasons your Postgres was not configured to accept
TCP connection.
It accepts only local connections through Unix sockets.
But pooler is not listening unix sockets because there is absolutely no
sense in pooling local connections.
I have done the same steps as you and have no problem to access pooler:
knizhnik@xps:~/postgresql.vanilla$ psql postgres -h 127.0.0.1 -p 6543
psql (14devel)
Type "help" for help.
postgres=# \q
Please notice that if I specify some unexisted port, then I get error
message which is different with yours:
knizhnik@xps:~/postgresql.vanilla$ psql postgres -h 127.0.0.1 -p 65433
psql: error: could not connect to server: could not connect to server:
Connection refused
Is the server running on host "127.0.0.1" and accepting
TCP/IP connections on port 65433?
So Postgres is not mentioning unix socket path in this case. It makes me
think that your server is not accepting TCP connections at all (despite to
listen_addresses = '*'
)
view thread (73+ messages) latest in thread
reply
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 using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected], [email protected], [email protected]
Subject: Re: Built-in connection pooler
In-Reply-To: <[email protected]>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox