I am currently building a HA cluster, the database is already on Galera, the last thing would be, trigger an DNS update to redirect the traffic to another machine.

Is there any software, which can monitor all 3 servers, and update the dns entry if needed? Basically It would just need to run a costum script on down and up of a node.

I know that DNS is not optimal, IP failover would be better, but since these servers are at 3 different networks, this is not possible.


  • Relying on DNS is not HA. It’s also not designed for this, although I know you can appreciate all that. How geographically different are these networks? Same country? – Timothy Frew Oct 6 '18 at 0:16
  • 1
    Changing DNS is a high availability technique with near-universal support. However, its slow response time and caching quirks does not compare well to HA clusters that respond quickly by steering connections or moving IPs. – John Mahowald Oct 6 '18 at 13:36

First, define which components of the stack are going to be on which nodes. Then draw a diagram of where you want the load balancing to happen.

Take a look at Galera documentation, cluster deployment variants. For example, if a copy of the DBMS and the app are both on each host, just connect the app to localhost. Or, if you want to have multiple paths to different databases, you would put that through a load balancer like a (SQL aware) proxy.

A load balancing aware DNS is called Global Server Load Balancing (GSLB). Sometimes these are used for incoming front end requests. For example, Polaris.

Same IP failover may not be feasible between different networks, especially where host specific routes or stretching layer 2 is forbidden. It is not needed for many applications.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.