BetterSWE DigestWhat is BetterSWE?

News · Issue 18

How a stale-check race in DynamoDB's DNS layer took down AWS US-EAST-1 for 14 hours

A stale DNS plan, a cleanup with no guard, and a retry storm that turned a 3-second wipe into a 14-hour regional collapse.

AWS US-EAST-1 region going dark with DynamoDB at the center

October 20, 2025

A 3-second DNS wipe, a 14-hour regional collapse

AWS US-EAST-1 region going dark with DynamoDB at the center

On Monday, October 20, 2025 at 06:48 UTC, DynamoDB's regional endpoint (dynamodb.us-east-1.amazonaws.com) started returning an empty DNS record. Every IP address was gone. The outage lasted roughly 14 hours, hit 140 AWS services, and took down Slack, Snapchat, Ring, and Coinbase.

The root cause was a Time-of-Check-Time-of-Use race condition in DynamoDB's internal DNS management system. A stale DNS plan, applied late by a lagging component, overwrote a newer plan, and a cleanup process with no guard against deleting the active state wiped the record entirely.

  1. 06:48 UTC: DNS wiped
  2. 09:40 UTC: DNS restored
  3. Afternoon: EC2 congestive collapse
  4. 20:50 UTC: Full recovery

DynamoDB is a foundational layer-one service, so its 3-hour outage cascaded into EC2's physical server management and Network Load Balancers. DNS was back by 09:40 UTC, but the regional damage was just getting started.

The race condition

Three enactors, one stale plan, no guard

DNS Planner and three Enactors with a race between stale and fresh plans

DynamoDB manages its own DNS via a DNS Planner that monitors load balancers and generates plans, plus three independent DNS Enactors (one per AZ: us-east-1a, 1b, 1c) that apply those plans to Route 53.

TOCTOU — Time-of-Check-Time-of-Use: a race where a system validates a state, then acts on it, but the state changes between validation and use.

The race: a slow enactor overwrites the fresh plan, then cleanup deletes it

One DNS Enactor hit extreme latency, 10x to 100x normal, while applying an older plan. Meanwhile the Planner generated newer plans, a second Enactor applied them, and triggered a cleanup to delete old plans. The slow Enactor finally committed its stale plan, overwriting the newer state. The cleanup process, lacking any guard against deleting active records, then deleted that plan too.

The system had corrupted its own state and could not auto-recover.

Manual operator intervention took over 2 hours to fix the DNS empty state. The system had no path to self-heal because every component believed it had done the right thing.

Cascading failure

How a DNS wipe became a congestive collapse

Cascade from DynamoDB outage to EC2 DWFM collapse to NLB flapping

EC2 uses the Droplet Workflow Manager (DWFM) to manage physical servers, and DWFM stores lease heartbeats in DynamoDB. During the 3-hour DynamoDB outage, DWFM could not complete state checks, and broken leases spiked from roughly 10^2 to 10^5.

Congestive collapse — A metastable failure state where a queue grows so long that work times out before it is processed, so the system stays alive but makes no forward progress.

The cascade: DynamoDB returns, but the recovery attempt itself becomes the failure

When DynamoDB returned, DWFM tried to re-establish all leases simultaneously. The queue grew so long that work timed out before completion, entering congestive collapse. Engineers had to restart DWFM servers to drop in-memory queues; EC2 launches stayed impaired until 20:50 UTC.

The launch backlog also delayed Network Manager's state propagation, so new instances came up without network connectivity. NLB health checks failed on these isolated instances, marked them unhealthy, then passed them later once networking caught up, causing constant capacity flapping.

What changes now

Disabling automation, adding guardrails

AWS adding guardrails and throttle controls to DNS and EC2 systems

AWS has disabled the DynamoDB DNS Planner and DNS Enactor automation worldwide until the race condition is fixed. The cleanup that deleted the active DNS record had no guard against removing the current state, and that gap turned a stale write into a regional outage.

Before

no guard on cleanup, no rate limit on recovery

After

guard active DNS, throttle lease storms

On the EC2 side, AWS plans velocity controls for NLBs to limit capacity removal during AZ failovers, and queue-size-based rate-limiting to prevent future congestive collapse.

The broader pattern is metastable failure. The DNS race was the trigger, but the 14-hour duration came from downstream systems that entered self-reinforcing bad states and could not climb out without human intervention.

Wrap-up

A 3-second wipe with a 14-hour tail

Why it matters

The outage exposes how a foundational service's internal control plane can fail in ways its public API never hints at. DynamoDB's DNS management ran its own planner, enactors, and cleanup logic with no guard against deleting the active state, and the 14-hour tail came from downstream systems that entered self-reinforcing bad states. Regional availability is only as strong as the weakest internal automation in the services underneath yours.

The short version

  • A TOCTOU race in DynamoDB's DNS management wiped all IP addresses for the regional endpoint at 06:48 UTC on Oct 20, 2025.
  • One slow DNS Enactor applied a stale plan, then a cleanup process with no guard deleted the active record.
  • DynamoDB's 3-hour outage cascaded into EC2's DWFM (congestive collapse from 10^5 simultaneous lease retries) and NLB flapping.
  • 140 AWS services were affected; full recovery took roughly 14 hours, ending at 20:50 UTC.
  • AWS disabled DNS Planner/Enactor automation worldwide and plans velocity controls for NLBs and queue-based rate limiting for EC2.

Sources

  1. 1.More Than DNS: The 14 hour AWS us-east-1 outage – Jonathon Belotti [thundergolfer]
  2. 3.AWS Outage Analysis: October 20, 2025
  3. 6.Demystifying the postmortem from Monday's AWS outage
  4. 11.Race Condition in DynamoDB DNS System: Analyzing the AWS US-EAST-1 Outage - InfoQ
  5. 12.Summary of the Amazon DynamoDB Service Disruption in the Northern Virginia (US-EAST-1) Region, 2025-10 | Ernest Chiang