This is a weird one. When using password auth, some entries in .pgpass make pg_autoctl to error when setting up replication, despite entries being valid and working fine with pg_receivewal
12:16:45 23 DEBUG pgsql.c:504 Connecting to [upstream] "postgres://pgautofailover_replicator@db-0.db:5432/?application_name=pgautofailover_standby_2&sslmode=prefer&replication=1"
12:16:45 23 WARN pgsql.c:595 Failed to connect to "postgres://pgautofailover_replicator@db-0.db:5432/?application_name=pgautofailover_standby_2&sslmode=prefer&replication=1", retrying until the server is ready
12:16:45 23 DEBUG pgsql.c:640 PQping(postgres://pgautofailover_replicator@db-0.db:5432/?application_name=pgautofailover_standby_2&sslmode=prefer&replication=1): slept 3 ms on attempt 2
12:16:45 23 DEBUG pgsql.c:654 PQping OK after 2 attempts
12:16:45 23 DEBUG pgsql.c:468 Connection to database failed: connection to server at "db-0.db" (10.1.0.234), port 5432 failed: fe_sendauth: no password supplied
It looks like a problem with .pgpass, but I belive that .pgpass is fine, because if get into standby node failing container, I can run replication without entering password:
This is a weird one. When using password auth, some entries in .pgpass make
pg_autoctl
to error when setting up replication, despite entries being valid and working fine withpg_receivewal
This .pgpass on a node works:
This doesnt:
With following error:
It looks like a problem with
.pgpass
, but I belive that.pgpass
is fine, because if get into standby node failing container, I can run replication without entering password:Environment
docker image
All components run as docker containers, see Dockerfile included below
Dockerfile
``` # syntax = docker/dockerfile:1.3-labs ARG POSTGRES_VERSION=14 ARG TIMESCALEDB_VERSION=2.5.0 FROM postgres:${POSTGRES_VERSION}-bullseye ## pg_auto_failover RUN curl -L https://repos.citusdata.com/community/gpgkey | apt-key add - COPY <