Ryan Lambert: Postgres 19 Upgrade from Postgres 15

2026年11月28日

AI 摘要 AI 生成,可能有误

本文概述了作者将生产数据库从 Postgres 15 升级到 Postgres 19 的计划,后者于 2026 年 11 月发布。由于忙于其他项目而跳过了第 16 至 18 版本,作者现在面临着紧迫的时间表,因为 Postgres 15 将于 2027 年 11 月达到生命周期终点(EOL)。这篇文章分享了他升级过程中的笔记,并着重介绍了值得探索的激动人心的新特性,但并未说明如何执行实际的升级操作。

Postgres 19 was released in November 2026 and once again I am planning production upgrades. This post has a few notes about my own upgrade process and highlights a few exciting new features to explore. This post does not explain how to perform the actual upgrade.

My own process is a bit unusual because I typically go through major version upgrades either annually or every other year at most. I upgraded to Postgres 15 shortly after it was released in 2022 and intentionally skipped Postgres 16 because I knew I would be occupied preparing for a full-day pre-conference session on PostGIS for PASS 2023. I ultimately skipped upgrades to 17 and 18 because... well, I was busy! However, this leaves me with less than a year to upgrade since Postgres 15 will become End of Life in November 2027.

继续阅读全文

为了尊重作者,这里只展示开头几段。你可以去原文阅读,或者在 HorizonReader 里读:划线做笔记、让 AI 帮忙。

更多来自 Planet PostgreSQL

Hubert 'depesz' Lubaczewski: Missed in PostgreSQL 19 : Toggle logical decoding dynamically based on logical slot presence.

AI 摘要On 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.

Jobin Augustine: Stop Fighting Synchronous Replication: Meet WAIT FOR LSN – Part 2 – walkthrough for DBAs

AI 摘要This 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.

Christophe Pettus: All Your GUCs in a Row: session_preload_libraries

AI 摘要This 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.

Umair Shahid: How a 40 TB PostgreSQL Cutover Took One Night

AI 摘要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.

Dimitri Fontaine: What Changes for SQL in PostgreSQL 19

AI 摘要This 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.