Questions tagged [database-replication]

Database replication is used to ensure consistency between redundant databases and to improve reliability and increase fault-tolerance. The replication process commonly involves continuously duplicating a "master" database to one or more additional "slave" databases.

Database replication can be used on many database management systems, usually with a master/slave relationship between the original and the copies. The master logs the updates, which then ripple through to the slaves. The slave outputs a message stating that it has received the update successfully, thus allowing the sending (and potentially re-sending until successfully applied) of subsequent updates.

1836 questions
4
votes
3 answers

How to find mysql DB is slave?

How to find mysql DB is slave with out using "show slave status" by query?
Tree
  • 9,532
  • 24
  • 64
  • 83
4
votes
1 answer

PostgreSQL — measure logical replication lag

Is there a way to measure logical replication lag in PostgreSQL?
Max Malysh
  • 29,384
  • 19
  • 111
  • 115
4
votes
2 answers

Mysql replication in shared hosting

I need to do some mysql replication. Some informations : I have two databases instances, in shared hosting, so I can't use Mysql Replication (I don't have access to the configuration files). It's for a non profit project (educational) so we can't…
Loïc Février
  • 7,540
  • 8
  • 39
  • 51
4
votes
2 answers

One way replication between Cassandra data centres

We are proposing Cassandra to be implemented as a database backend for a large archiving solution (a large number of writes compared to reads). We are looking for inputs on Cassandra's replication and deployment strategy to fit our use case. The…
4
votes
1 answer

How to Update Stats and Rebuild Indexes in Azure Geo-Replicated Database

I have a Geo-Replicated Azure SQL Database which has some serious index fragmentation and outdated statistics. An attempt to REORGANIZE or REBUILD an index, or to UPDATE STATISTICS results in the message "Failed to update database xxx because the…
4
votes
1 answer

Cross region replication of Google Cloud Postgresql instances

From my understanding of their documentation, the cloud postgresql service, being beta, does not yet support external replicas, which is what i thought i could use if i wanted a database to be replicated cross region. This could very well end up…
omu_negru
  • 4,642
  • 4
  • 27
  • 38
4
votes
2 answers

Android - Couchbase lite - pull with filter - Replication.setFilter

I'm working on a android messagerie app, messages are stored in a CouchDB(Apache) database on the internet. How can I pull messages with filter on my Android devices? Android Snippet: Replication pull = new Replication(messageDB, messageUrl,…
Anh-Tuan Mai
  • 1,129
  • 19
  • 36
4
votes
2 answers

Is there any tool available to parse mysql binlog file in row format and create json

I have mysql binlog enabled in row format. I am using mysqlbinlog to parse binlog file. I am using this command: mysqlbinlog --base64-output=decode-rows -vv ./mysql-bin.000004 This command returns sql statements that I have to parse to generate…
Branel Moro
  • 132
  • 2
  • 9
4
votes
2 answers

Anonymous transactions get made even with GTID_MODE=ON

I'm using MySQL 5.7 with GTID master-master replication and I'm experiencing a strange error. Randomly one of my masters will stop replicating with: "Cannot replicate anonymous transaction when @@GLOBAL.GTID_MODE = ON" When I check there is indeed…
Nick
  • 594
  • 2
  • 7
  • 18
4
votes
1 answer

How reliable is master-slave replication?

I was watching this screencast at RailsLab where the presenter claims that it's possible to have a master DB for write operations and a slave DB for read operations. While for certain types of Web sites (e.g. blogs, social networks, Web 2.0 sites,…
Behrang
  • 46,888
  • 25
  • 118
  • 160
4
votes
1 answer

Hibernate configuration for MongoDB loadbalancing

I have got a small mongoDB cluster with 3 nodes (no sharding, only replication). Now the insertion to the primary node is propogating the new data to the secondary node as expected (basic replication). I am using java and hibernate. Now what I want…
Obaid Maroof
  • 1,523
  • 2
  • 19
  • 40
4
votes
2 answers

Load Balancing using HAProxy for Postgresql 9.4

I have made a setup of multi-master replication of PostgreSQL using BDR (Bi-Directional Replication) among 4 nodes (virtual machines). Now i want to put a load-balancer for High Availability. For this i have installed and configured "HAProxy" on a…
4
votes
1 answer

How can I setup mongo replica set with ansible?

I have two machines hosting one mongo instance each. I need them to work together as a replica set. I use Ansible for my provisioning. How can I achieve that ?
Raphaël
  • 1,924
  • 2
  • 18
  • 22
4
votes
1 answer

Creating a new MySQL replica from an existing replica

I'm using a standard MySQL replica setup with a single master and a single replica. Now I want to create a new replica so that I have one master and two replicas. To setup the new replica, I wanted to do a MySQL dump of the existing replica instead…
metajungle
  • 85
  • 1
  • 3
4
votes
1 answer

Database replication when the application is launched offline

I use PouchDB to store data offline and synchronize with a remote CouchDB database when the application goes online. It works well if the app is launched online: PouchDB triggers the pause event when the connexion is interrupted and continues when…
hhh
  • 1,913
  • 3
  • 27
  • 35