16 Feb Bursting MongoDB to a Remote Kubernetes Cluster in Minutes: Part 3 — Failover and Wrap-up
In part two of this series, we demonstrated how to burst MongoDB on-demand to another Kubernetes with minimum operations and complexity. We had our complete cross multi-cloud setup enabled by ionir, bringing up the additional node in under 40 seconds using Teleport. The following graphic illustrates the environment and components as configured in part two.
Optional Step — Failover
This setup can enable cloud migrations under the same process. Let’s say once we decide to turn-off MongoDB services on Cluster A, all the workload’s operations — Reads and Writes — can be utilized from Cluster B without fully syncing the data thanks to the ionir name-based data services layer.
To simulate this, the only thing we actually need to do is to delete the Kubernetes LoadBalancer service (kubectl delete svc mongodb
) on Cluster A, which will trigger the failover process on Route53. All new sessions will get redirected to Cluster B automatically from a networking perspective. The MongoDB ReplicaSet will take care of the rest. Using voting and priority election process, the Secondary
node will change to Primary
and continue serving queries.
If you would like to safely perform a transition from Secondary
to Primary
, you can run the following command to force the remote cluster’s MongoDB node to be voted as Primary
before actually failing over.
cfg = rs.conf()
cfg.members[2].priority = 200
rs.reconfig(cfg)
Final Thoughts
Container-native storage provides high-performance storage for Kubernetes deployment. And in doing so, offers common data management and protection workflows across hybrid and multi-cloud deployments. With ionir Kubernetes Native Storage, enterprises can eliminate legacy storage to reduce infrastructure and operational costs by over 40%!
ionir is the only Kubernetes storage platform designed to adapt to technology changes and evolving customer needs without forklift upgrades. Manage your enterprise data more efficiently and cost-effectively than ever before. Contact our team of experts to get started.