MySQL with Glusterfs Storage vs MySQL replication with hostPath storage

MySQLreplication

I am trying to search right road in a project.

We have currently three nodes openshift cluster(okd 3.11) and deployed MySQL with Glusterfs storage. its working fine but look like over engineered to me.

I am thinking to replace above with MySQL Replication with hostpath storage so 1 node be master and other node will act as slave. this way no need for extra steps to deploy glusterfs storage.

We may not extend this cluster it will be three and if we may have to deploy two node OKD cluster MySql replications will be ideal choice as Glusterfs dont recommend to use less then 3 nodes.

Main goal is HA so graceful failover can be achieved. Any thoughts?

Best Answer

The minimum for an HA setup is 3 nodes, geographically distributed.

  • If you put all the nodes in a single data center, you are vulnerable to a datacenter crash. (They do happen.)
  • If you use Master + Slave(s), failover is not well automated. See MHA as a possible alternative.
  • With Galera cluster, you can write to all nodes, thereby helping minimize downtime. (I don't know about Glusterfs.)