Sample Header Ad - 728x90

pcp_attach_node: username and/or password does not match for user "postgres"

0 votes
0 answers
54 views
I am setting up pgpool for the first time, using a two-node cluster. The primary node is on 10.6.1.129 and the secondary node is on .131.
backend_hostname0 = '10.6.1.129'
backend_port0 = 5433
backend_weight0 = 1
backend_data_directory0 = '/opt/data/data15_new'
backend_flag0 = 'ALLOW_TO_FAILOVER'
backend_hostname1 = '10.6.1.131'
backend_port1 = 5433
backend_weight1 = 1
backend_data_directory1 = '/opt/data/data15_new'
backend_flag1 = 'ALLOW_TO_FAILOVER'
I have load balancing working effectively. When I bring the secondary node down it fails over successfully to the primary. When I bring the secondary back up, the failback doesn't work. The logs give this:
main pid 411463: LOG:  reaper handler
main pid 411463: LOG:  reaper handler: exiting normally
child pid 411463: LOG:  failover or failback event detected
child pid 411463: DETAIL:  restarting myself
main pid 411463: LOG:  reaper handler
main pid 411463: LOG:  reaper handler: exiting normally
child pid 411463: LOG:  failover or failback event detected
child pid 411463: DETAIL:  restarting myself
main pid 411463: LOG:  reaper handler
main pid 411463: LOG:  reaper handler: exiting normally
child pid 411463: LOG:  failover or failback event detected
child pid 411463: DETAIL:  restarting myself
main pid 411463: LOG:  reaper handler
main pid 411463: LOG:  reaper handler: exiting normally
child pid 411463: LOG:  failover or failback event detected
child pid 411463: DETAIL:  restarting myself
This group appears multiple times, but if I look at the pgpool_status file, node 2 is still down:
up
down
Doing some further investigation I tried to manually add the node back. In theory since the DB was only down for a few seconds and I believe I've found the issue:
$pcp_attach_node -h 127.0.0.1 -n 1 -v
FATAL: authentication failed for user "postgres"
DETAIL: username and/or password does not match
I reset the password for postgres and put the password in my .pgpass file, but the error persists. Is there another place that I should put the postgres password to get pcp to recognize it?
Asked by Adam Blomeke (1 rep)
Jan 24, 2025, 03:32 PM
Last activity: Jan 24, 2025, 03:33 PM