Answer the question
In order to leave comments, you need to log in
What are the modes of operation of MySQL replication?
Good afternoon, ladies and gentlemen.
I have a small question for the experts.
On Habré there is a wonderful article about master-master replication
habrahabr.ru/company/bitrix/blog/146490
Suppose there are two servers - the main and the backup.
Let's say the master-master replication mode is configured. There was a situation when the main server crashed, but changes to the database continue to be made, therefore, only to the database on the standby. Then the main server is turned on, and this is where the question arises, what will happen for different modes (active-active, active-passive)? Is it possible to read about it somewhere?
Sorry if the question is inappropriate. I’m not an expert on the topic, but after reading the articles I didn’t find an answer to my question, I can’t understand if there will be a difference in the operation of these modes.
Answer the question
In order to leave comments, you need to log in
And there is only one active-passive mode, and you completely provide the filer yourself, then it’s up to you to decide what to do at such a moment.
If one, then why is there such a division into active-active and active-passive?
Maybe a little late, but suddenly someone else will open this ticket:
There is a Master -> Slave
mode There is a Master <-> Master mode (It should be considered as two Master -> Slave replications). In this mode, each server works both as a Master and as a Slave. This mode is used in two cases:
1) If the code that uses the database was originally designed to work with master-master replication
2) When you need to quickly switch between servers. (In this option, you do not spend too much time updating the database, the database is updated itself, since it constantly reads changes from the servers that occur on the active server)
The stability of the first option depends on the directness of the hands of programmers who implement the interaction of the code with the databases, the stability of the second option rather depends on the directness of the hands of the admins.
Also in the implementation of mysql-server version 5.6 (we are talking about linux-systems, I don’t know what is on Windows) it is possible to create a mysql-cluster. This feature has not been tested by me personally, however, this does not make it non-existent.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question