Re: Postgres 13 streaming replication standby not sending password, 'fe_sendauth: no password supplied'

From: Laurenz Albe <laurenz(dot)albe(at)cybertec(dot)at>
To: "Keaney, Will" <will(dot)keaney(at)kroger(dot)com>, "pgsql-general(at)lists(dot)postgresql(dot)org" <pgsql-general(at)lists(dot)postgresql(dot)org>
Subject: Re: Postgres 13 streaming replication standby not sending password, 'fe_sendauth: no password supplied'
Date: 2024-01-11 08:55:03
Message-ID: 348f10200facc875103601ef92d86cfd4567e1ed.camel@cybertec.at
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Wed, 2024-01-10 at 22:51 +0000, Keaney, Will wrote:
> However, the standby is unable to authenticate to the primary to begin recovery during startup.
> It logs an error, "FATAL: could not connect to the primary server: fe_sendauth: no password supplied".
>
> pg_hba.conf on the primary:
> host all,replication repl primary-database-server scram-sha-256
> host all,replication repl standby-database-server scram-sha-256
>
> myrecovery.conf on the standby:
> primary_conninfo = 'host=primary-database-server port=5432 user=repl application_name=standby-server-name'
> recovery_target_timeline = 'latest'
> primary_slot_name = 'standby_replication_slot'
>
> .pgpass on the standby:
> # hostname:port:database:username:password
> *:*:replication:repl:repl_user_password

make sure that .pgpass is in the home directory of the PostgreSQL user and has
restrictive permissions (0600). Try using it with a manual connection attempt
via "psql".

Yours,
Laurenz Albe

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Alban Hertroijs 2024-01-11 15:06:05 Time zone offset in to_char()
Previous Message Ron Johnson 2024-01-10 23:22:49 Re: Postgres 13 streaming replication standby not sending password, 'fe_sendauth: no password supplied'