Skip to main content

PostgreSQL案例

PostgreSQL Operations Experience 2025

·5942 words·28 mins
A 2025 summary of PostgreSQL operations experience covering CPU, memory, IO, WAL, autovacuum, locks, partitioned tables, connection pools, statistics, and other core operational topics with practical tips and troubleshooting

Case: Partition Data UPDATE Failure on 2026-01-01

·1367 words·7 mins
Analysis of UPDATE failure on new partitions without primary keys: partitioned tables under logical replication publications lack replica identity; PG11 publication mechanism combined with partition creation workflow results in new partitions missing both primary keys and indexes

Case Study: Row Locks and LWLock LockManager

·2063 words·10 mins
Analyzing how high-concurrency updates on the same row cause massive row locks and LWLock LockManager waits, verifying through benchmarks that row locks bypassing the fastpath mechanism is the root cause of increased LWLock contention

Case: GRANT Authorization Causes Walsender to Hang

·1613 words·8 mins
Analysis of GRANT authorization causing walsender to freeze: massive pg_class changes from bulk GRANT produce huge numbers of invalidation messages; logical decoding stalls due to pathman plugin's slow hash table traversal during invalidation processing

PostgreSQL Ops Experience 2024

·5612 words·27 mins
A summary of PostgreSQL operations experience in 2024, covering execution plan regressions, statistics collection strategies, connection pooling, vacuum, WAL, partitioned tables, and other common ops issues with quick diagnosis and resolution approaches