I am new here so take good care of me. I want to make failover cluster out of 2 debian 8.5 servers with mysql database. I need that both of them work on one ip (virtual). Can you suggest what clustering program to use and how to configure it? Thank you in advance.
Asked
Active
Viewed 379 times
-1
-
1Can you explain your scenario more? – Orphans Oct 21 '16 at 06:06
-
I have two identical physical servers running debian 8.5 64 bit with mysql database. Mysql is configured to Master-Slave replication (don't know how to make Master-Master). We are using database for accounting programs. So I need to do that if first one server fails automatically second server gets virtual ip and we can work without interruption and when first server is fixed ip should switch to it. I tried with pacemaker and corosync one year back, but no success. I tired to find what configuration I did back then, but can't find it. I want to try make cluster from scratch. – Deividas Kaleckas Oct 21 '16 at 07:38
-
If you have more details relating to your question, you should [edit] the question to improve its quality. If relevant details are buried in the comments, users may not see them – and you’re decreasing your chances of getting good answers. See [ask]. – Anthony Geoghegan Oct 21 '16 at 14:02
-
keepalived or a tcp proxy can handle the virtual IP part of this. Setting up a MySQL cluster is probably outside of the scope of this website because ultimately it boils down to a shopping/scaling question. – Daniel Widrick Oct 21 '16 at 15:04
-
I suggets you go with gallera as @drookie suggested below. – Orphans Oct 21 '16 at 20:09
1 Answers
1
I would start with ucarp (for some weird reason I don't see the debian manual in the Internet, but I hope it's the same in Ubuntu). However, thorough explaining of how to maintain the integrity of the MySQL database in a group of two servers is beyond the scope of this answer (because of the complexity of the topic), but Mysql Router is worth mentioning. Plus, I would stick to some kind of master-master replication, for example Galera Cluster, or even MySQL NDB cluster (however, latter one operates using some alien logic (sql profiles for known queries will change drastically), which requires rewriting the entire project for it - I recommend considering it with caution).
Once again, this topic is too broad.
![](../../users/profiles/165991.webp)
drookie
- 8,051
- 1
- 17
- 27