Umair Shahid: How a 40 TB PostgreSQL Cutover Took One Night
Dec 1, 2026
AI summary AI-generated, may contain mistakes
A regulated payments company successfully migrated over 40 TB of production data to a new EDB Postgres cluster with a single-night cutover, made possible by months of preparation using a replication-based approach. Key lessons included sizing the timeline around the largest tables (8.6 TB and 4.5 TB), using parallel workers to speed up backfill, monitoring WAL growth on the source, and building regulatory notice periods into the schedule. The team also stresses post-cutover 'hypercare' monitoring for a week, which caught a standby replication lag early and prevented potential production issues.
A regulated payments company just moved more than 40 TB of production data onto a new EDB Postgres cluster. The cutover started at 2 AM local time. By morning, the application was back online, and the client’s team confirmed in writing that every post-cutover validation check had passed.
That night was quiet because of everything that happened in the months before it. In September I wrote about pushing this go-live date back on purpose, and about the playbook we use to de-risk a mission-critical migration. This post is the follow-up. It covers what we learned once the data got big, what actually set the timeline, and what the week after cutover looks like.
The biggest table sets the date
Keep reading
Out of respect for the author only the opening is shown here. Read the rest on the original site, or in HorizonReader with highlights, notes and AI help.
AI summaryOn December 23, 2025, Masahiko Sawada committed a patch to PostgreSQL that allows logical decoding to be toggled dynamically based on the presence of logical replication slots. Previously, logical decoding required wal_level to be set to 'logical' at server start, meaning users had to bear the overhead of logical-level WAL logging even when no logical replication slots were in use. Despite this improvement, the feature was missed in PostgreSQL 19.
AI summaryThis article is Part 2 of a series on PostgreSQL 19's WAIT FOR LSN feature, offering DBAs a hands-on walkthrough using just two psql sessions to demonstrate read-your-writes consistency on replicas, timeout handling with NO_THROW, monitoring waiting sessions, and how WAIT FOR behaves when a standby is stuck compared to synchronous replication. It also explains the feature's errors and restrictions—such as being unusable while holding snapshots or locks and only allowed as a top-level statement—showing why each exists to prevent deadlock cycles with recovery. Finally, it recounts the feature's long development history, including multiple commits and rejections over more than six years.
AI summaryThis blog post by Christophe Pettus discusses the PostgreSQL parameter session_preload_libraries, reaffirming the earlier advice to use it instead of local_preload_libraries. The author notes that despite the parameter's simple job of calling dlopen(), there is more fine print to explain than expected, starting with the fact that its default value is empty.
AI summaryThis article analyzes what PostgreSQL 19.0, released on November 19, changes for SQL, based on running the queries from The Art of PostgreSQL on versions 19.0 and 18.6 and reading the final release notes. The findings include 7 headline features withdrawn before release, 11 changes affecting existing SQL, roughly 20 new features, and an 8-step upgrade checklist. While release-day posts emphasize REPACK, plan advice, and ON CONFLICT DO SELECT, the change with the most consequences for existing SQL is that the planner now reads NOT NULL constraints and rewrites queries with them.
AI summaryThis article, the first in a three-part series, introduces PostgreSQL 19's WAIT FOR LSN feature, which allows applications to wait until a given WAL position has reached a standby, offering a flexible alternative to synchronous replication. It explains the drawbacks of synchronous replication—such as all commits hanging indefinitely when a standby fails, with statement_timeout providing no help—and demonstrates how combining WAIT FOR LSN (with modes like standby_replay and standby_flush) with synchronous_commit = off gives per-transaction durability and read-your-writes guarantees. The author also covers important caveats, including timeout handling, connection pool sizing on the standby, and critical tuning of wal_writer_flush_after and wal_writer_delay, while cautioning readers to wait for PostgreSQL 19.1 before production use due to a bug in 19.0.