[Bucardo-general] what to do when master-master replication failed?

Itamar Reis Peixoto itamar at ispbrasil.com.br
Sat Dec 10 14:27:11 UTC 2011

On Sat, Dec 10, 2011 at 8:24 AM, Yan Chunlu <springrider at gmail.com> wrote:
> hi, all:
> I have just tried bucardo and found it is great to do master-master
> replication, especially for me that I have two master db across
> datacenter which has 200ms latency.
> currently I am planning to using bucardo to do master-master
> replication, plus repmgr to do master-slave replication in case one
> master failed. I only sync the tables, and the sequences are seperate
> with odd and even.

you can use bucardo for both master-master and master-slave.

> like this:
> DC1                         DC2
> master1(odd)           master2(even)
> slave1                      slave2
> what I am wondering is, database always have a chance to fail, in my
> use case, both master need to be alive all the time, because they all
> need to accept writes.

you can use pgpool or change your application to connect to one server
and case fail connect to the next server.

> so once a master died, I need to promote the slave immediately, but
> then what happened with bucardo synchronizer?  could I just change the
> server ip in bucardo's database?   because the master-slave is using
> PITR, all the schema, triggers, users would be the same between master
> and slave.
> If that could work, I think it should be the way to handle failover.
> I can not afford for even one of the master to fail.    thanks for all the help!


Itamar Reis Peixoto
msn, google talk: itamar at ispbrasil.com.br
+55 11 4063 5033 (FIXO SP)
+55 34 9158 9329 (TIM)
+55 34 8806 3989 (OI)
+55 34 3221 8599 (FIXO MG)

More information about the Bucardo-general mailing list