Scrivio Interview library
ConceptFoundations6 min read · updated 13 November 2026

Redundancy means running more copies of a component than the load needs, so one can fail without an outage. A web service needs 12 instances at its daily peak and runs in a region with three availability zones.

How many instances should it run, and where, to survive losing one zone at peak? What do N+1 and N+2 mean, and how do hot, warm and cold standbys differ in recovery time and cost?

To survive losing one of three zones at peak, the two remaining zones must carry all 12 instances' worth of work, so we run 6 per zone and 18 in total, 50 percent extra; with two zones we would need 12 in each, 100 percent extra. N+1 means one spare unit beyond peak need and N+2 also covers a failure during maintenance, where at zone level the unit is a whole zone. Hot standbys recover in seconds to a minute, warm in minutes and cold in hours, at falling cost, so each component's recovery time objective decides which one it gets.

Why this question is asked

Redundancy sounds simple, run extra copies, but the details decide whether it actually prevents an outage. How many extra copies, placed where, kept in what state, and failing for which reasons? Interviewers ask this question because the arithmetic is easy to get wrong under pressure, and because the vocabulary (N+1, hot and cold standby) comes up in every availability discussion. In this answer, we will recap zones and why they matter, work out the instance count, explain N+1 and N+2, compare hot, warm and cold standbys, and finish with the condition that makes all of it work: independent failure.

1A Quick Recap of Zones

A cloud region, such as one geographic area of a provider, is divided into availability zones. Each zone is one or more data centers with its own power, cooling and network, a few kilometres from the others and connected by fast links. Zones are designed to fail independently, so a power cut or a fibre cut takes out one zone, not the region.

Our service needs 12 instances at its daily peak. That number is the capacity requirement, usually called N. Redundancy is anything beyond N that lets us lose part of the fleet and still serve the peak.

2Working Out the Instance Count

If we spread instances evenly over three zones and one zone fails, we keep two thirds of them. Those survivors must carry the full peak of 12. So each zone needs 12 / 2 = 6 instances, and the total is 6 x 3 = 18. That is 6 more than N, or 50 percent extra capacity.

Now compare two zones. If one fails, the single survivor must carry all 12, so each zone needs 12 and the total is 24, which is 100 percent extra. Notice that adding a third zone gives the same protection more cheaply. In general, with Z zones, the extra capacity needed to survive one zone loss is 1 / (Z - 1) of N.

Instances needed to survive one zone loss at a peak of 12
ZonesPer zoneTotalExtra over N
21224100%
361850%
441633%
More zones, less waste, as long as the zones fail independently.

There is one more detail. Instances in the failed zone may not die cleanly; some may be half alive. So the load balancer's health checks must remove them quickly, or the survivors will not get the traffic they were provisioned for.

3What N+1 and N+2 Mean

N+1 means we run one spare unit beyond what the peak needs. If one unit fails, we still have N. N+2 means two spares, and the usual reason for the second one is maintenance: during a planned upgrade one unit is already out of service, and N+2 still survives an unplanned failure at that moment. Many teams discover the need for N+2 the hard way, when a zone fails during a rolling deployment.

Notice that the unit depends on what we are protecting against. For instance failures, the unit is one instance, and N+1 for our service is 13. For zone failures, the unit is a whole zone, so N+1 at zone level is the 18 instances over three zones we calculated. Saying N+1 without naming the unit is a common source of confusion in design reviews.

4Hot, Warm and Cold Standbys

A standby is a copy waiting to take over. A hot standby runs all the time and receives replicated state or live traffic, such as a database replica kept in sync or extra instances behind the same load balancer; failover takes seconds to about a minute. A warm standby runs at reduced size, and failover means scaling it up or promoting it, which takes minutes. A cold standby does not run at all; we build it after the failure from images, infrastructure code and backups, which takes hours.

Cost moves the opposite way to recovery time. Hot costs nearly a full copy; cold costs little more than storage. So the choice is not one rule for the whole system. Each component gets the standby that matches its recovery time objective (RTO), the longest acceptable time to restore it. The checkout database might need a hot replica, while an internal reporting tool can live with a cold rebuild.

Standby types compared
TypeWhat runsRecovery timeCost
HotFull copy, synced state or live trafficSeconds to a minuteHighest
WarmSmaller copy, needs scaling or promotionMinutesMedium
ColdNothing; rebuilt from images and backupsHoursLowest

5Redundancy Needs Independent Failure

All of this assumes the copies fail independently. Eighteen instances across three zones protect us only if nothing they all share can fail at once. Shared dependencies quietly undo redundancy: a single config server every instance reads at startup, one disk array behind all the databases, one deployment pipeline that pushes a bad build everywhere at once, or one DNS provider.

So we spread copies across zones, power and network paths, and we look for the hidden single points of failure. A practical question for every component is: if this one thing fails, how many of our copies fail with it? If the answer is all of them, we do not have redundancy for that failure, however many instances we run.

6Follow-up questions

Why does a quorum-based database need three zones rather than two?

A quorum system, such as etcd, a Raft-based database or a PostgreSQL cluster managed with Patroni and a consensus store, accepts a write only when a majority of members agree. With members in two zones, one zone holds the majority, and if that zone fails the survivor cannot form a majority, so the cluster stops accepting writes. Splitting evenly is worse: neither side has a majority. With one member in each of three zones, any single zone can fail and the other two still form a majority of two out of three, so the cluster keeps working.

Is 50 percent extra always enough?

Only for one zone failure and only if the 12 at peak is right. If traffic grows, or a bad deployment takes out instances while a zone is down, we need more. Teams usually add a margin and review it against growth every quarter.

Can autoscaling replace the extra capacity?

Not safely. Autoscaling needs new instances to launch during the event, when the provider's control plane may be slow or throttled. Pre-provisioned capacity works without any action, which is why critical services keep the static headroom.

7Conclusion

In this answer, we saw that surviving one zone loss at a peak of 12 needs 6 per zone and 18 in total across three zones, half the extra of a two-zone design. We defined N+1 and N+2 and noted that the unit matters, compared hot, warm and cold standbys by recovery time and cost, and saw that redundancy only helps when the copies fail independently.

What to say in the interviewAbout 90 seconds aloud

Open with

The service needs 12 instances at peak, and with three zones, losing one leaves two thirds of the fleet. Those two zones must carry all 12, so I would run 6 per zone, 18 in total, which is 50 percent extra.

Then, if they want more

With only two zones each would need all 12, so 24 in total and 100 percent extra, which is why three zones give the same protection more cheaply. N+1 means one spare unit beyond what peak needs, so one failure is absorbed.

N+2 adds another, which covers a failure while one unit is already out for maintenance, like during a rolling deploy. The unit matters: for instance failures it is one instance, but for zone failures it is a whole zone.

For standbys, a hot standby runs all the time with replicated state or live traffic and takes over in seconds to a minute; a warm standby runs smaller and needs scaling or promotion, so minutes; a cold standby is built after the failure from images and backups, so hours.

Cost falls from hot to cold, so I choose per component based on its recovery time objective. And I would add that none of this helps unless the copies fail independently, so I look for shared dependencies like one config server, one disk array or one deployment pipeline.

About this answer

Last updated
13 November 2026
Checked
Its structure and format are checked automatically. Use it as a carefully prepared study note: where a detail matters, confirm it against the official documentation for the version you use. What the checks cover
Where the question comes from
Written by Scrivio for practice. It is not taken from an interview.
Report an issue with this answer

Copy the line below and send it to the author with what you found. It carries the address of this page.

Issue with "How many instances should it run, and where, to survive losing one zone at peak? What do...": https://scrivio-interview-library.netlify.app/architecture/high-availability/8a27a9a0ab/