VOOZH about

URL: https://thenewstack.io/use-multi-availability-zone-kubernetes-for-disaster-recovery/

⇱ Use Multi-Availability Zone Kubernetes for Disaster Recovery - The New Stack


TNS
SUBSCRIBE
Join our community of software engineering leaders and aspirational developers. Always stay in-the-know by getting the most important news and exclusive content delivered fresh to your inbox to learn more about at-scale software development.
REQUIRED
It seems that you've previously unsubscribed from our newsletter in the past. Click the button below to open the re-subscribe form in a new tab. When you're done, simply close that tab and continue with this form to complete your subscription.
The New Stack does not sell your information or share it with unaffiliated third parties. By continuing, you agree to our Terms of Use and Privacy Policy.
Welcome and thank you for joining The New Stack community!
Please answer a few simple questions to help us deliver the news and resources you are interested in.
REQUIRED
REQUIRED
REQUIRED
REQUIRED
REQUIRED
Great to meet you!
Tell us a bit about your job so we can cover the topics you find most relevant.
REQUIRED
REQUIRED
REQUIRED
REQUIRED
REQUIRED
Welcome!

We’re so glad you’re here. You can expect all the best TNS content to arrive Monday through Friday to keep you on top of the news and at the top of your game.

What’s next?

Check your inbox for a confirmation email where you can adjust your preferences and even join additional groups.

Follow TNS on your favorite social media networks.

Become a TNS follower on LinkedIn.

Check out the latest featured and trending stories while you wait for your first TNS newsletter.

PREV
1 of 2
NEXT
VOXPOP
As a JavaScript developer, what non-React tools do you use most often?
Angular
0%
Astro
0%
Svelte
0%
Vue.js
0%
Other
0%
I only use React
0%
I don't use JavaScript
0%
Thanks for your opinion! Subscribe below to get the final results, published exclusively in our TNS Update newsletter:
NEW! Try Stackie AI
From clobbered drafts to real-time sync
Apr 14th 2026 10:00am, by David Moore
TypeScript 6.0 RC arrives as a bridge to a faster future
Mar 14th 2026 9:00am, by Darryl K. Taft
Mastra empowers web devs to build AI agents in TypeScript
Jan 28th 2026 11:00am, by Loraine Lawson
2022-03-21 06:57:51
Use Multi-Availability Zone Kubernetes for Disaster Recovery
contributed,sponsor-ondat,sponsored,sponsored-post-contributed,
Kubernetes / Networking / Software Development

Use Multi-Availability Zone Kubernetes for Disaster Recovery

Kubernetes provides a functionality that we can use to build a solution to the problem of stateful multi-AZ Kubernetes deployments.
Mar 21st, 2022 6:57am by Nicolas Vermande
👁 Featued image for: Use Multi-Availability Zone Kubernetes for Disaster Recovery
Feature image via Pixabay
Ondat sponsored this post.
Nicolas Vermandé
Nicolas is the principal developer advocate at Ondat. He is an experienced hands-on technologist, evangelist and product owner who has been working in the fields of cloud native technologies, open source software, virtualization and data center networking for the past 17 years. Passionate about enabling users and building cool tech solving real-life problems, you'll often see him speaking at global tech conferences and online events.

Outages and degraded performance are inevitable. Operators make mistakes; new protocols introduce errors, natural disasters damage equipment and more.

That’s why rather than trust Amazon’s ability to design a hurricane-proof data center, most platform managers opt to spread their application’s infrastructure across multiple availability zones (AZs).

AZ outages aren’t terribly common, but they do occur, and degraded performance is even more common. And a catastrophic outage such as one caused by a hurricane is possible, so responsible platform managers design their infrastructure around failure.

This is a good instinct and one that should be applauded. But few platform managers consider the new design challenges that multi-AZ Kubernetes deployments can create. Let’s dive in and explore the new factors a multi-AZ production environment poses.

Can’t I Just Distribute My Infrastructure Across AZs?

Multi-AZ Kubernetes services will likely require more legwork than simply declaring that you want your nodes distributed across AZs. While it’s technically possible that you’ll be able to simply deploy replica nodes across multiple AZs, most applications will require additional configuration.

Specifically, stateless applications will work fine across multiple AZs. If one AZ goes down, Kubernetes will reschedule your app in the next AZ. There won’t be any stateful workloads to preserve over the transition so the end-user won’t notice anything different.

A stateful application, however, won’t just work across multiple AZs. Here’s why.

Statefulness Across AZs

Let’s say you’ve launched an application across multiple AZs to gain disaster recoverability, but you didn’t take its stateful workloads into account.

First, your application won’t function correctly for long since it’s operating with stateful workloads across containers, which aren’t very robust when it comes to running stateful applications.

Say there’s a spike in demand or some other kind of failure that forces Kubernetes to kill a container. When Kubernetes’ scheduler restarts your stateful app, it will only run if it happens to be restarted in the same AZ where its volume was initially located. If it’s restarted elsewhere, it won’t have access to that volume anymore. Thus, platform administrators must create and maintain affinity rules for apps with attached volumes to ensure they restart only in the AZ associated with their volumes.

But let’s assume that you’ve established a workaround to this issue, possibly by leveraging a suitable Container Storage Interface (CSI) provider that is not constrained by AZ boundaries. If disaster recovery is a goal, then you’ll want to ensure that your solution enables you to create persistent volume replicas. That way, if one container fails, your replicas can immediately pick up the slack with little to no downtime.

But now, you have another challenge: ensuring that your replicas are evenly distributed across AZs. For example, it’s possible that your primary volume and its replicas could be located all in the same AZ, which will obviously affect your disaster recoverability in the event that AZ goes down or experiences a service interruption.

Furthermore, you’ll need to identify a way to change where your replicas are hosted over time. What happens if you decide to add another AZ or change the layout of your replicas? Kubernetes and your cloud service providers’ infrastructure won’t do this for you automatically.

To get around this, you might script something custom in Lambda, if you’re primarily using AWS for cloud services. But then there’s something else for you to maintain, and of course, this won’t work across different cloud service providers.

Ondat delivers persistent storage volumes directly onto any Kube node. If your data is locked-in to one platform, so is your cluster. With Ondat you are free to put your applications and your data storage where you want. Ensuring industry-leading levels of performance, resilience and dependability.
Learn More
The latest from Ondat

The Solution: Kubernetes’ Topology Key

Fortunately, Kubernetes provides a functionality that we can use to build a solution to the problem of stateful multi-AZ Kubernetes deployments called a topology key. This enables Kubernetes services to route traffic based on the node topology of a cluster.

So, one way to use the topology key is to have Kubernetes label each node with the AZ in which it is located. With this information, a CSI solution can then distribute replica nodes such that they are evenly distributed across AZs, thereby creating a robust disaster recovery capability otherwise missing from Kubernetes’s feature set.

Kill Two Birds with One Stone

The above approach is exactly what Ondat takes. Using Kubernetes’s topology key, Ondat distributes replica nodes across AZs in a process called topology-aware placement.

Ondat also ensures your stateful workloads persist whenever an AZ, cluster, node or container goes down. As a storage orchestrator, ​​Ondat pools your individual nodes’ storage and acts as an intermediary Kube-native distributed engine, thus separating and abstracting your frontend persistent volumes from the underlying platform topology.

If you’re curious about how Ondat works, you can learn more here.

Ondat delivers persistent storage volumes directly onto any Kube node. If your data is locked-in to one platform, so is your cluster. With Ondat you are free to put your applications and your data storage where you want. Ensuring industry-leading levels of performance, resilience and dependability.
Learn More
The latest from Ondat
TRENDING STORIES
Nicolas Vermandé is the senior developer relations manager at Spectro Cloud. He is an experienced hands-on technologist who has been working in the fields of cloud native technologies, open source software, virtualization and data center networking for the past 17...
Read more from Nicolas Vermande
Ondat sponsored this post.
SHARE THIS STORY
TRENDING STORIES
TNS owner Insight Partners is an investor in: Pragma.
SHARE THIS STORY
TRENDING STORIES
TNS DAILY NEWSLETTER Receive a free roundup of the most recent TNS articles in your inbox each day.
The New Stack does not sell your information or share it with unaffiliated third parties. By continuing, you agree to our Terms of Use and Privacy Policy.