I tried setting up the Multi master BDR for postgres, by following the steps provided in the quickstart. I Managed to get the installation and configuration correct(hopefully).
I have two centos 7 servers: X and Y. Where postgres, bdr both were installed.
After adding the entry in pg_hba.conf, postgresql.conf. Restarted the postgres instances on both the server.
my pg_hba.conf have on both X and Y:
host replication postgres X/32 trust
host replication postgres Y/32 trust
Also, postgresql.conf is added with changes provided in the quickstart.
I was able to create bdr extension and btree_gist.
On X machine:
select bdr.bdr_group_create(local_node_name :='node1', node_external_dsn :='port=5432 dbname=testDB host=IPADDRESS_of_X', node_local_dsn := NULL, apply_delay := NULL, replication_sets :=array['status']);
on Y machine:
select bdr.bdr_group_join(local_node_name := 'node2', node_external_dsn := 'port=5432 dbname=testDB host=IPADDRESS_of_Y', join_using_dsn := 'port=5432 dbname=testDB host=IPADDRESS_of_X', node_local_dsn := NULL, apply_delay := NULL, replication_sets :=ARRAY['status']);
For Testing I ran,
select bdr.bdr_node_join_wait_for_ready();
This returned null as expected.
select '*' from pf_relication_slots;
this gave a slot name with my testDB.
However, when I ran a manual update or insert on the database, I see that the data is not replicating on other node.
SELECT * FROM bdr.bdr_nodes
Does gives the output as:
Could someone please help me on this.