FlareStart
HomeNewsHow ToSources
FlareStart

Where developers start their day. All the tech news & tutorials that matter, in one place.

Quick Links

  • Home
  • News
  • Tutorials
  • Sources
  • Privacy Policy

Connect

© 2026 FlareStart. All rights reserved.

Back to articles
Racing Against 2 Billion: How We Survived a PostgreSQL Transaction ID Wraparound on a 2TB Production Table
NewsDevOps

Racing Against 2 Billion: How We Survived a PostgreSQL Transaction ID Wraparound on a 2TB Production Table

via Dev.to DevOpsParth Mishra1mo ago

A detailed account of diagnosing and recovering from a near-fatal transaction ID wraparound on a high-traffic production PostgreSQL database — and the unexpected twist that turned a 60-second operation into 50 minutes of downtime. TL;DR : Our production PostgreSQL hit 1.6B transaction IDs (limit is ~2.1B) on a 2TB table. Normal vacuum failed for weeks due to excessive bloat. Vacuum freeze ran for 6 days and got stuck. We dropped 800GB of unused indexes and ran pg_repack as a last resort. pg_repack worked perfectly until the final step, where PostgreSQL's own anti-wraparound autovacuum blocked the ACCESS EXCLUSIVE lock needed to complete the swap — causing 50 minutes of downtime instead of 60 seconds. We killed autovacuum, pg_repack finished, XIDs dropped from 1.6B to 440M, and vacuum that used to take days now runs in 2.5 hours. Full timeline and lessons below. The Alert Nobody Worries About (Until They Should) On a quiet Tuesday morning, a monitoring alert fired: MaximumUsedTransactio

Continue reading on Dev.to DevOps

Opens in a new tab

Read Full Article
24 views

Related Articles

20+ pocket-sized tech gadgets packed with purpose (and they're on sale)
News

20+ pocket-sized tech gadgets packed with purpose (and they're on sale)

ZDNet • 6h ago

We still highly recommend these 3 older laptop models - especially while they're on sale
News

We still highly recommend these 3 older laptop models - especially while they're on sale

ZDNet • 7h ago

RefundYourSOL (RYS): Recovering Lost Value in the Solana Ecosystem
News

RefundYourSOL (RYS): Recovering Lost Value in the Solana Ecosystem

Medium Programming • 7h ago

News

Best Free Developer Tools Online (2026)

Medium Programming • 8h ago

Go’s Error Evolution: Best Practices for Cleaner, More Inspectable Code in 2026
News

Go’s Error Evolution: Best Practices for Cleaner, More Inspectable Code in 2026

Medium Programming • 8h ago

Discover More Articles