11 ms·
> Both PostgreSQL and Cassandra have mature replication frameworks Speaking of Postgres - master/slave replication is fairly easy and seems to work well. But t
by Florin_Andrei 11y ago
> Both PostgreSQL and Cassandra have mature replication frameworks
Speaking of Postgres - master/slave replication is fairly easy and seems to work well. But trying to implement master/master replication is painful. There are some external solutions like Bucardo, which is basically a Perl-based service that handles replication outside of PG (yikes!); there's BDR which is integrated with the main PG daemon, but it's not production ready. And this is only asynchronous replication.
Any suggestions for sane, reliable master/master replication with PG that simply works?
- vladsanchez 11y agoIf not mistaken, Skype used or still uses plProxy. Check it out! - https://wiki.postgresql.org/wiki/PL/Proxy https://wiki.postgresql.org/wiki/PL/Proxy - https://github.com/plproxy/plproxy https://github.com/plproxy/plproxy - http://highscalability.com/skype-plans-postgresql-scale-1-billion-users http://highscalability.com/skype-plans-postgresql-scale-1-bi... Don't be confused with the 'partitioning' term. It's used in 'horizontal' partitioning context.
- fancy_pantser 11y agoHere's a table: https://wiki.postgresql.org/wiki/Replication,_Clustering,_and_Connection_Pooling#Comparison_matrix https://wiki.postgresql.org/wiki/Replication,_Clustering,_an... It's worth noting that BDR is much more mature that the table indicates and is probably the easiest to set up today (for up to 48 masters in a pool).
- Florin_Andrei 11y agoI did a test with a data backup from our live DB, and BDR fails in mysterious ways. I had a two-node cluster, and tried to restore the DB into one node. Failed, I think, when it was rebuilding indexes (no useful messages in the logs), with some scary warnings also when it was importing some big tables. Most of the data made it across network to the other node - emphasis on most. I really wanted this thing to work. :( On paper it looks great.
- SEJeff 11y agoPostgres has no good equivalent of Galera. MySQL has no good equivalent of barman.
- scurvy 11y agoMaster/master looks good on paper and glossy product hand-outs, but it doesn't work out well in production. You'll find every case or performance problem that causes it all to break horribly. Facebook doesn't do master-master on their MySQL instances. It's all master-slave(s). Why? Because it works, it's reliable, and it's easy to change masters quickly when you have Facebook's automation infrastructure.