I have some data logs sent to a mySQL database on server1. Sometimes, due to the power failure, the server1 shuts down. I need the logs to be sent to mySQL database on server2 and then, when server 1 is up, to synchronize everything, so no logs can be lost. Is this a possible thing, or do you recommend something else?
Asked
Active
Viewed 37 times
1 Answers
1
Sounds like you're looking for master-master type replication. What generally happens in this instance is you'll have 2 MySQL servers (a and b we'll say). A will be designated primary and B will start off as slave. So when an update is done to A through my.cnf configuration it'll be sent to B and they stay in sync. In the event A crashes (power outage, hard drive failure, etc) a process will detect the server is down and make B the new master. Then once A is fixed and back online it'll come on as the slave. This isn't overly difficult to set up, check out how to's such as: how to forge hope that helps!

DPP
- 11
- 2
-
Thank you very much for your time! – catalin Nov 23 '16 at 15:10