[Bucardo-general] General clarifications about users permissions
Rodrigo Rodovalho
rodrigo.rodovalho at gmail.com
Mon Jul 6 02:56:29 UTC 2020
Hi,
I'm having a little trouble setting up the correct postgres permissions of
the databases involved in a two element multi-master environment. I would
like to describe here my understanding and gently ask for clarifications in
what is wrong. In my tests, I was able to make it work while the tests were
made in a single machine using pgbench. Now, with two, I'm having constant
authentications failures.
My setup is a multi-master environment, master-1 and master-2.
-----------------------------------------------------------------------------------------
- Master-1:
* IP: master_1_ip
* Target Database:
> Name: database_name
> User: user_name
> Password: password_1
* Bucardo Database:
> Name: bucardo
> User: bucardo
> Password: bucardo_pass_1
* pg_hba.conf:
> local bucardo bucardo md5
> local database_name bucardo md5
-----------------------------------------------------------------------------------------
- Master-2:
* IP: master_2_ip
* Target Database:
> Name: database_name
> User: user_name
> Password: password_2
* postgresql.conf:
> listen_address = 'master_2_ip'
* pg_hba.conf:
> master_1_ip database_name user_name md5
-----------------------------------------------------------------------------------------
My commands so far, on Master-1:
$ bucardo add db database_local dbname=database_name
$ bucardo add db database_remote dbname=database_name port=5432
host=master_2_ip user=user_name password=password_2 <---- This connection
works fine!
$ bucardo add dbgroup database_group database_local:source
database_remote:source
$ bucardo add all tables relgroup=tables_group <---- ISSUE HERE:
"FATAL: Peer authentication failed for user "bucardo" at line 64" (it
really says *peer*)
$ bucardo add sync sync_name telgroup=tables_group
dbgroup=database_group
In the steps above, I'm a little confused about what each produces in terms
of database iterations. For instance, in the "bucardo add all tables..."
command, what is happening? Maybe a step by step explanation of
which database are being worked could help...
Please Notice:
- In both masters, the target's database name and database user are the
same.
- In each master, the user's passwords are different.
Thanks in advance for any help.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://bucardo.org/pipermail/bucardo-general/attachments/20200705/b3e3edb0/attachment.htm>
More information about the Bucardo-general
mailing list