Module 13 · Project 13 · Design a Production AWS Architecture · Lesson 42 of 48

Design for failure

Everything fails eventually. Learn how a production AWS setup survives a dead server, a failed database and a lost data center, and copes with traffic spikes.

In this lesson · about 35 minutes

  • Find and remove single points of failure
  • Explain availability zones, load balancers, Auto Scaling and Multi-AZ databases
  • Use caching and a CDN to handle load

Everything fails, all the time

At cloud scale, servers die, disks fail and, now and then, a whole data center loses power. You can't prevent that. You can design so that no single failure takes the app down. Start by looking for single points of failure: anything there's only one of, whose loss stops everything.

The building blocks

  • Regions and availability zones: a region (us-east-1) has several AZs: separate data centers with their own power and networking, a few miles apart. Put copies of everything in at least two AZs.
  • Application Load Balancer (ALB): spreads requests across healthy instances in all AZs and stops sending traffic to any that fail health checks.
  • Auto Scaling group (ASG): keeps a set number of instances running, replaces unhealthy ones, and adds or removes instances with load (for example, target 50% CPU). On Kubernetes (EKS), the HPA and cluster autoscaler play this role.
  • RDS Multi-AZ: a synchronous standby copy of the database in another AZ. If the primary fails, RDS promotes the standby in a minute or two; the endpoint name stays the same. Read replicas are different: they spread read load, and may lag.
  • ElastiCache (Redis): keeps sessions and hot data in memory, so app servers are stateless (any server can handle any user) and the database does less work.
  • CloudFront (CDN) with S3: serves images, CSS and JS from locations near users. Most requests never reach your servers.
  • Route 53: DNS with health checks, and later, failover to another region (Project 14).

Networking and security

Same layout as Project 06, grown up: the ALB in public subnets; app servers, cache and database in private subnets with no public IPs; security groups chained ALB → app → database. Admin access goes through SSM Session Manager, not open SSH ports. The WAF on the ALB or CloudFront blocks common attacks. Everything is encrypted with KMS. IAM roles, least privilege, CloudTrail and GuardDuty are covered step by step in Cloud Security (AWS).

Prefer managed services

Running your own database cluster on EC2 means patching, backups and failover are your job at 3 am. Managed services (RDS, ElastiCache, EKS, SQS, S3) do that for you. You pay a bit more per hour, but spend far fewer engineer-hours.

Try it · watch it run

A production AWS architecture you can break

Start with all the design choices on and try each failure. Then turn choices off one at a time (one AZ, no Multi-AZ database, no Auto Scaling, no CDN) and replay the failures. Which choice protects you from which failure?

Design choices

Break something

Route 53DNS + health checks
CloudFrontCDN · S3 static files
ALBpublic subnets, both AZs

Zone A · private subnets

EC2 a1
EC2 a2
RDS primary
ElastiCachesessions, hot reads

Zone B · private subnets

EC2 b1
EC2 b2
RDS standbysynchronous copy
what happens
Pick a failure to see how this design copes.
Healthy. Every request has more than one place it can go.

Whiteboard · watch and try

What does 99.9% need?

Press Play. The tutor shows why two copies beat one.

4 steps
Press Play and the tutor will talk you through it while writing on the board. Pause any time to write on the board yourself.

Tip: press Pause, then use the pen to work along on the board. Space plays and pauses; Ctrl+Z undoes your last mark.

Sorting drill

Which failure does it protect against?

Match each design choice to the failure it handles.

  • ALB health checks with 2+ instances
  • Instances spread over two AZs
  • ASG target tracking on CPU
  • RDS Multi-AZ standby
  • CloudFront serving static files

0 of 5 sorted

Check your understanding0 of 3 correct

Question 1

1.What's the difference between RDS Multi-AZ and a read replica?

Question 2

2.Why keep app servers stateless?

Question 3

3.How should admins reach private instances?

Key terms

Say the meaning to yourself, then tap a card to check.

Quiz score: 0 of 3

Tip: answer every quiz question correctly first.

Written by Noviq Academy in its own words. The labs are simulations: no real servers are touched. When you build the projects yourself, use a practice virtual machine or a free-tier cloud account you control, watch your cloud spending, and never run cleanup or delete commands on a machine you care about. Tool names belong to their owners; versions and output are shown for learning and may differ slightly from yours. Read-aloud and the whiteboard voice use your device's built-in voices.