Failover instances of DHIS2

I’m looking for a guide on configuring one DHIS2 instance as a fail-over for another. Is this an easy(ish) thing to accomplish?
First prize would be a seamless failover without admin intervention.
Second prize would be for a live mirror server that can be quickly configured to take over as the primary server in an emergency situation.

We have two production instances of DHIS2 - one for aggregate data and one tracker instance. I’m thinking of a container based architecture that has both tracker and aggregate instance on the same physical box mirrored with a backup box of identical configuration that could take over in case of system failure.

Thanks!

1 Like

Hi Edward,

At BAO Systems, we’ve setup a system wherein there is a load balancer, with anywhere between 3 and 6 Tomcat servers running, there is a also a Redis server running, to handle caching/sessions and the like, and of course a Postgres DB, with the option of a fail over replica. Our configuration is based on the documentation found here:
https://docs.dhis2.org/master/en/implementer/html/install_web_server_cluster_configuration.html#

It should be noted though that this isn’t containerized or the exact solution you’re asking for and our setup relies heavily on Amazon Web Services to operate, but it does provide resilience if something happens that brings down a Tomcat server.

2 Likes

Thanks Dan, so to clarify, the solution uses Amazon specific features to handle the redundancy? So implemented at platform level essentially? I’ll look into cluster options for on premise solution. Thanks!

We don’t use AWS on the platform level per se, there are still ec2 instances running CentOS and we’re using RDS running Postgres. Was just sharing our experience of having a clustered version running in production and I didn’t want to imply “just 3 clicks to a clustered solution.” If you’d like to chat in more detail feel free to email me dcocos@baosystems.com and I’ll try to post a summary back to the DHIS2 Community.