Joao Miguel Ferreira <joao.miguel.c.ferreira@gmail.com> writes:
> On Thu, Feb 4, 2021 at 2:26 PM hubert depesz lubaczewski <depesz@depesz.com>
> wrote:
>>> My database is not listening on TCP/localhost, desptite it is listening
>>>> on the unix socket. How can I investigate this?
> it's on 5433:
Hmm, something odd there, because a port number mismatch should have
resulted in psql failing to connect via unix socket either. Maybe
you have more than one active postmaster?
Anyway, given these settings, "psql -p 5433 -h localhost" should
connect. If you still get "connection refused" then you need to
look at the kernel firewall (packet filter) settings.
regards, tom lane