Questions tagged [master-master]

4 questions
6
votes
1 answer

Master-Master replication broken with "Duplicate entry for key 'PRIMARY'" due to AUTOINCREMENT

We use Master-Master replication to avoid situations in which writing to replica will get it out of sync with the real master and in case we wish to switch masters. However, there's a seemingly known problem with AUTOINCREMENT fields which causes a…
Collector
  • 2,034
  • 4
  • 22
  • 39
0
votes
0 answers

Copying Postgres database to another server with smallest downtime

I'm going to migrate a production PostgreSQL 12 database (~200GB) to another more powerful server. There are a bunch of partitioned tables, some without primary key (theoretically, it won't be a problem to temporarily add them if needed). Is there…
0
votes
1 answer

MySQL Master-Master Replication Error: "Error Connecting to Master" Error 2003

Context: I'm migrating a MySQL 5.7.42 database from an existing external (to AWS) CentOS 7 server to a new private subnet Ubuntu 22 AWS EC2. Due to the nature of the surrounding architecture, I require a temporary master-master sync. The databases…
0
votes
0 answers

Does table locking work in MariaDB master-master Replication?

I'm considering MariaDB master-master configuration for a webapp database. My application has some index locking, something like: SELECT COUNT(*) FROM person WHERE event=? FOR UPDATE; The transaction checks the subscribers amount to an event and…
Tobia
  • 9,165
  • 28
  • 114
  • 219