Menu

max_wal_size, explained
📰

max_wal_size, explained

DEV Community: postgres·Wojtek Pastyrczyk·10 days ago
#wajRyaEo
#devtopostgresql#devto#dev#postgresql#server
Reading 0:00
15s threshold

max_wal_size gives PostgreSQL's transaction log a size budget. Some write-heavy servers outgrow the 1 GB default - and when that happens, PostgreSQL is forced to write the same data to disk again and again. We explain what the setting really does, how to reduce that wasted disk work using your server's own counters, and when to leave it alone.

The setting that is easy to overlook

Every busy PostgreSQL server writes more to disk than the application asks it to. Some of that extra work is normal and healthy. But on write-heavy systems, part of it can be repeated, avoidable work - and how much of that happens is heavily influenced by one setting: max_wal_size . Nothing in daily operation points at it, and the advice that is easy to find online is generic - a fixed number, or a calculator that cannot see your workload.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.