Cloudflare Cuts 100 TB of Memory from 1.1.1.1 DNS Cache

Leela Kumili ยท rss ยท 2026-09-23 Reader ๐Ÿ–ฅ๏ธ

Distributed Caching & InvalidationInfrastructure EfficiencyRust (Programming Language)
Cloudflare cut its DNS cache's per-entry memory footprint by 56% and freed ~100 TB of fleet-wide working-set memory, without sacrificing (and while improving) throughput and latency, by collapsing the in-memory representation of cache entries toward DNS wire format instead of a typed, allocation-heavy Rust structure.

theoretical ยท expository โ€” News reporting on an engineering result: the author explains what Cloudflare changed and why it worked (understanding), not arguing that the reader should take a specific action. The implicit practical payload โ€” 'represent cache data closer to wire format, avoid boxing enum variants' โ€” is carried by the reporting rather than argued for directly.

Structure

PartRole
Opening headline results (footprint -56%, ~100 TB freed, throughput +43%, latency -19%)conclusion / thesis statement
Scale context (250B+ entries) and Sebastiaan Neuteboom's LinkedIn quotecontext / human-scale framing
The five successive Rust representation changes (Box<[T]>/Box<str>, combined record lists, bitflags, owner-name omission, enum-boxing failure)evidence / mechanism
Reddit commenter's scale-dependence caveatcounter-context / qualification
Final design description (contiguous byte buffer in DNS wire format)conclusion of the mechanism narrative
Comparison to Unbound and PowerDNS Recursor cache architecturescontext / differentiation
Production rollout data (May 18โ€“July 6 2026, p99/p90 memory) and benchmark numbers (per-entry footprint, allocations)evidence / validation
Closing statement on reinvesting freed memory into cache capacityconclusion / implication

Key terms

Propositions

Arguments

Storing DNS cache records as a contiguous byte buffer in (near-)wire format, rather than as parsed/typed Rust structures with per-field allocations, is the superior in-memory representation for a high-volume DNS cache. strength: high
Explicit premises:
Implicit premises:
Inferences:
The specific memory-representation techniques Cloudflare applied โ€” especially avoiding boxed enum variants in favor of inline/contiguous storage โ€” are not universally good practice; they are contingent on operating at very high request volume. strength: low
Explicit premises:
Implicit premises:
Inferences:

Narratives

Questions addressed

Gaps

Related documents