Questions tagged [master-slave-replication]

The tag has no usage guidance.

95 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
4
votes
0answers
2k views

Queries running very slowly in Amazon RDS PostgreSQL read-replica

We have been maintaining a project which has both web and mobile application platform. The backend of the project is developed in Django 1.10 and deployed in AWS. At the beginning, when there were ...
3
votes
0answers
434 views

Replication doesn't resume once it fails to connect

We have MySQL replication running for our application. Right now the slave fails to resume if it fails to connect to the server for some time. We get the error below: [ERROR] Slave I/O: error ...
3
votes
0answers
7k views

Slave is not configured or failed to initialize properly. You must at least set --server-id to enable either a master or a slave

I am trying to setup multi source replication. In my slave I have defined following two properties in its configuration file. master-info-repository=table relay-log-info-repository=table These ...
2
votes
1answer
22 views

MariaDB - Replication - Unable to login remotely

So I've been trying to configure MariaDB replication for our server. Unfortunately I cannot get it replicating correctly. So I've followed the MariaDB guide to the letter to get replication set up. ...
2
votes
0answers
28 views

How I can find out which postgresql I am connected into when behind a load balancer?

I have the following database replication setup: As you can see I do a master-slave replication and I use aload balancer in order to connect into read-only replicas. So I want to test this setup, ...
2
votes
0answers
262 views

How to get the Slave commit timestamp using MySql replication?

I've been looking for ways to collect information about the replication delays on MySql 8. I found an alternative solution, but I imagine there's a more straightforward way to do that. By reading its ...
2
votes
1answer
586 views

Mongodb replica set primary and secondary node conf fail when one slave is down

In my env, I had created MongoDB replica set conf for high availability so one server fails should be handled by other also in my conf I have 3 DB server and 1 arbiter too but, my slave's server ...
2
votes
1answer
178 views

Can I stop replication of create/drop index statement on one slave of Mysql 5.6?

I have this cluster where master and slave uses same indexes but one of the slaves has some extra indexes (large machine which runs some analytics queries). So I have to maintain two sets of indexes. ...
2
votes
1answer
149 views

Cross-Continent SQL High-Latency Data Synchronization

How would one go about synchronizing a MySQL database cross-continent, while keeping the distributed application using the DB running fast (<0.2s page loads) ? My database contains about 2.5GB of ...
2
votes
0answers
216 views

MongoDB not performing well when set Read from secondary

I have a mongoDB database, with 1 primary and 1 secondary in replicaset(and 1 arbiter). Both the servers are hosted on aws on c4.2xlarge instances(with 1.5 TB of SSD on each). Mongo version of primary ...
2
votes
0answers
515 views

Cluster using docker

We are creating a new application using microservices, and for that we would like to be able to raise database instances just like we raise new instances for the application's microservices. We do not ...
2
votes
2answers
1k views

Importing a large mysql dump while replication is running

So we have a simple master/slave mysql replication running between two CentOS Servers. The master has multiple databases. eg.. Database1 Database2 Database3 The issue is we have a mysql dumpfile ...
1
vote
1answer
20 views

Why is it not a good idea to use MariaDB's extra_port for replication?

MariaDB has an extra_port for administrative access that helps in cases the thread pool or main port is locked up. MariaDB's documentation says it's use case is primarily administrative access and it ...
1
vote
0answers
40 views

Getting error while starting slave on MySQL slave./ Backups in MySQL 8.0.20

I want to set up below command for daily MySQL database backup.suppose We have more than 50 MySQL database in server. I am using below command to take backup of all databases on server. Note: I am ...
1
vote
0answers
65 views

How to check RDS MySQL database synchronization status

We were creating a read replica for an RDS MySQL (5.7.28) instance, and before the read replica became available one of our developer accidentally connected to the read replica and was able to write ...
1
vote
1answer
35 views

Can a MySQL 5.6 master replicate to a 5.7 slave, which in turn replicates to a MySQL 8 slave?

According to the docs, "MySQL supports replication from one release series to the next higher release series. For example, you can replicate from a master running MySQL 5.6 to a slave running MySQL 5....
1
vote
0answers
138 views

RESET MASTER; does not reset GTID_EXECUTED

I'm trying to get replication up and running between two kubernetes pods, and am getting the dreaded @@GLOBAL.GTID_PURGED can only be set when @@GLOBAL.GTID_EXECUTED is empty. error. root@central-vm:~...
1
vote
1answer
72 views

MySQL 5.7 Can slave be ahead of master during replication

From my understanding, once commit() is received from client, transactions are written to binlog first before any commit is done to InnoDB. In this case, is it possible for slaves to be ahead of ...
1
vote
2answers
86 views

Split read/write requests over different read/write datasources

Recently I have run some performance tests on the application I work on, and it turns out that it didn't do really well ( the problem is mainly between the back and the DB). So as investigating the ...
1
vote
0answers
121 views

Physical and logical replication slots on Postgres (same time)

I wonder if it's possible to have a setup when changes from a single Postgres master streamed to two (or more) replicas same time, but some replicas to use streaming (logical) replication and some to ...
1
vote
1answer
343 views

Issue with Time Zone while migrating MySQL on-premises DB to AWS RDS

I am having MySQL 5.6 database with PST time format in on-premises server. Now we are willing to migrate the database to RDS. For this, we have taken backup from physical server and restored in RDS ...
1
vote
1answer
142 views

Postgresql streaming replication slow on macOS

I am using PostgreSQL 10.1 on MAC on which I am trying to set up streaming replication. I configured both master and slave to be on the same machine. I find the streaming replication lag to be slower ...
1
vote
1answer
299 views

PostgreSQL - Replica Recovery Process Stuck frequently (epoll_wait taking too much time)

We have Master Slave Setup with Asynchronous Streaming Replication (Replication Slots). Frequently our Replica's entire Postgres processes seems to be doing nothing (or stuck?). Since ...
1
vote
1answer
129 views

Finding temporary table name in MariaDB

As I reported some days ago to MariaDB bug tracker the following bug: https://jira.mariadb.org/browse/MDEV-17420, slave replicas with version 10.2.x are leaking temporary tables on MyISAM files. Our ...
1
vote
0answers
231 views

Cascading binary replication to logical postgres

Im using Postgres 10, and I was wondering if its possible to cascade a logical replication from a binary slave replica? I am looking to have databases with the same data but indexed in a different way ...
1
vote
1answer
726 views

Load balancing between 2 servers using MySQL Router

I want to setup a simple master-slave MySQL replication. I also want to balance the load between the 2 servers. Can I use MySQL Router 2.1 for that purpose? As I read the official documentation, it ...
1
vote
1answer
3k views

Mysql replication broken due to 'Duplicate entry' with error code 1062 on slave server

Mysql Slave replication was working fine, but suddenly it has crashed due to duplicate entries error The slave SQL thread stops due to duplicate entries in MySQL DB, which I have kept in ...
1
vote
1answer
277 views

Is it possible to create a MySQL slave from a MariaDB master?

I need to create a MySQL slave instance which replicates the data from a MariaDB master. (I guess it won't work.) Any advice on how to create this replica architecture using MariaDB and MySQL? I am ...
1
vote
0answers
78 views

When the master db fails, the slave db will enable the write mode. How do I synchronize the master db with the information written to the slave db?

have two database. They are db1 and db2. db1 master, slave at db2. d1 have write/read mode. d2 have read mode. I have a problem like this: When the master db fails, The slave db will enable the ...
1
vote
0answers
84 views

MySQL Lagging Slave Across Data Centers

We seem to have a strange issue from time to time during heavy write workload , a slave in a different data center starts to lag behind the master but when we STOP and START the slave the it starts to ...
1
vote
0answers
64 views

postgres 8.4: makeslave it's own master

For a DR test, I've tried to split the slave from the master. To do this, I edited the master postgresql.conf, turned off archive_mode and restarted. No problem. Now I'm trying to make the slave a ...
1
vote
0answers
123 views

Replicate Specific Tables with fully qualified statements removed

Currently we have a replication system that is a master to slave, which that slave is also a master. We are replicating our web server to our stats server so we can report on users traffic as well. We'...
1
vote
1answer
1k views

Slave stoping with Last_SQL_Errno: 1032

I have added an extra Slave server to an existing MySQL Replication. The Master server and the old Slave server are working fine without any issue, but the newly added server is stoping with the ...
1
vote
0answers
177 views

MySql slave thinks that the query didn't run on the master, no helpful error

We have a master-slave replication that was running perfectly until recently. Today i've found the error: Query caused different errors on master and slave. Error on master: message (format)='Size ...
1
vote
1answer
352 views

sync_binlog different for master and slave

Is it fine if sync_binlog is different for master and slave? For my system I can see master has sync_binlog=1 and slave has sync_binlog=0.
1
vote
0answers
258 views

Master-slave + master-master replication at the same time

Can a MySQL database which is doing master-slave replication to a number of slaves be configured to do master-master replication to a new server at the same time? I have an application that has a ...
1
vote
1answer
36 views

runtime replication

We have a master-master replication setup with 3 databases being replicated between both masters; 'database a', 'database b', 'database c'. Replication is row-based. 'database c' had an issue and we ...
1
vote
1answer
32 views

Lost entire MySQL Server. Unsure if “master-slave” or “master-master” - How to tell?

Yup - my db02 server lost a disk, and the array itself is corrupt (RAID5, yet corrupt data.) I was able to get the OS back online, but the corruption is severe. I have zero documentation about the ...
1
vote
1answer
360 views

Replication Hung - Seconds_Behind_Master Increasing

One of my slave is no longer replicating. The seconds_behind_master continue to increase, Exec_Master_Log_Pos does not increase, and Relay_Log_Space does increase. Slave_IO_Running and ...
0
votes
0answers
22 views

High Available PostgreSQL with Patroni and Replication

I want to build a highly available PostgreSQL cluster using patroni with etcd. I want to have 3 server (1 master and 2 slaves) in my cluster, so if something goes wrong one of the slaves automatically ...
0
votes
1answer
13 views

Fault tolerance for Database sharding and Database partitioning

I'm aware that database sharding is splitting up of datasets horizontally into various database instances, whereas database partitioning uses one single instance. In Database Sharding, what if one of ...
0
votes
0answers
16 views

Mysql replication is running poorly on one of the slaves with no apparent changes

We have been using a master with 2 slaves for as long as I can remember with no major issues. Both slaves are lower in specification than the master so I do expect there to be lags at times and have ...
0
votes
0answers
14 views

How to turn on GTID on MariaDB if already using binary/position replication?

MariaDB 10.3 current master config [mysqld] log-bin server_id=1 binlog-format=mixed expire_logs_days=10 current slave config [mysqld] log-bin server_id=2 binlog-format=mixed expire_logs_days=10 I ...
0
votes
2answers
34 views

Broken Slave MySQL : How To Fix MySQL Replication (BINLOG) error in the Slave?

Before we start I can give some info about the versions, Ubuntu - 14.04, MySQL - 5.5 I have successfully configured the Master-Slave replication with two EC2 Ubuntu instances. My master is in Ubuntu ...
0
votes
1answer
15 views

slow wal replay in backup postgres12 server

We have the following PG12 setup with Master, replica and readonly replica with archive. master and replica both has 2cpu, 4gb ram readonly replica with archive has 2 cpu, 2gb ram below you can ...
0
votes
1answer
16 views

PostgreSQL pg_rewind use cases

Let's say that I configured streaming replication between Server A (master) and Server B (slave). If server A goes down and Server B is promoted, would I be able to use pg_rewind, where Server B is ...
0
votes
0answers
34 views

PostgreSQL Streaming Replication with Switchover

I'm trying to provide streaming replication between a master (T1) and slave (T2) and swapping their roles when necessary (i.e letting T1 be a slave to T2). So far I am able to get this working if I'm ...
0
votes
0answers
32 views

MySQL 5.7 Master-Slave Replication Functional but Not Replicating New Records

I've got a Master-Slave topology set up with the following two servers: Master Information: OS: GNU/Linux Centos 7.6.1810 (Core) Kernel: 3.10.0-042stab140.4 MySQL version: 5.7.25 Server_id: 1 Slave ...
0
votes
0answers
45 views

Mysql 8 Replication and promoting slave to master

I am not using GTID based replication and I have only one master and one slave. This question is in general regarding Mysql 8 and I want to be prepared when I have to deal with production systems. I ...
0
votes
0answers
77 views

Mariadb replication slave broken

I run Mariadb 10.3 on a Debian 10.3 server. The database was standalone until now and worked fine. Now I want to set it up as a replication slave. I use this as a guide: https://www.linuxbabe.com/...