2
votes

I experience some problems using bucardo add db command. It looks like it's unable to connect to other postgreSQL databases. I tried to do it in several ways. With pg_hba.conf setting

"local" is for Unix domain socket connections only: local all postgres ident

/usr/local/src/bucardo-5.3.1# ./bucardo add db cd_db dbname=hq

Connection to "cd_db" (PostgreSQL database) as user bucardo failed. You may force add it with the --force argument. Error was: fe_sendauth: no password supplied

Then with pg_hba.conf setting

"local" is for Unix domain socket connections only: local all all peer

with postgres credentials:

/usr/local/src/bucardo-5.3.1# ./bucardo add db cd_db dbname=hq db dbuser=postgres

Connection to "cd_db" (PostgreSQL database) as user postgres failed. You may force add it with the --force argument. Error was: FATAL: Peer authentication failed for user "postgres"

with bucardo credentials:

/usr/local/src/bucardo-5.3.1# ./bucardo add db cd_db dbname=hq db dbuser=bucardo dbpass=bucardo-runner

Connection to "cd_db" (PostgreSQL database) as user bucardo failed. Error was: FATAL: Peer authentication failed for user "bucardo"

Please help me to figure out what is wrong and how to use the installed bucardo. I'm running it on Linux Debian, just for reference.

1

1 Answers

1
votes

To use ident to login with a different user other than the linux user you will need to map the user in pg_ident.conf.

pg_indet.conf
app             root                    postgres
app             root                    bucardo
app             {username}              bucardo

pg_hba.conf
local   all         all                                     ident map=app