This is the multi-page printable view of this section. .
Resource Usage
- 1: autovacuum_work_mem
- 2: backend_flush_after
- 3: bgwriter_delay
- 4: bgwriter_flush_after
- 5: bgwriter_lru_maxpages
- 6: bgwriter_lru_multiplier
- 7: commit_timestamp_buffers
- 8: dynamic_shared_memory_type
- 9: effective_io_concurrency
- 10: file_copy_method
- 11: file_extend_method
- 12: hash_mem_multiplier
- 13: huge_page_size
- 14: huge_pages
- 15: io_combine_limit
- 16: io_max_combine_limit
- 17: io_max_concurrency
- 18: io_max_workers
- 19: io_method
- 20: io_min_workers
- 21: io_worker_idle_timeout
- 22: io_worker_launch_interval
- 23: io_workers
- 24: logical_decoding_work_mem
- 25: maintenance_io_concurrency
- 26: maintenance_work_mem
- 27: max_files_per_process
- 28: max_notify_queue_pages
- 29: max_parallel_maintenance_workers
- 30: max_parallel_workers
- 31: max_parallel_workers_per_gather
- 32: max_prepared_transactions
- 33: max_stack_depth
- 34: max_worker_processes
- 35: min_dynamic_shared_memory
- 36: multixact_member_buffers
- 37: multixact_offset_buffers
- 38: notify_buffers
- 39: old_snapshot_threshold
- 40: parallel_leader_participation
- 41: replacement_sort_tuples
- 42: serializable_buffers
- 43: shared_buffers
- 44: shared_memory_type
- 45: subtransaction_buffers
- 46: temp_buffers
- 47: temp_file_limit
- 48: timing_clock_source
- 49: transaction_buffers
- 50: vacuum_buffer_usage_limit
- 51: work_mem
Dossier URLs remain flat; this category exists only to organize browsing and the sidebar.
1 - autovacuum_work_mem
Fact — official short description: “Sets the maximum memory to be used by each autovacuum worker process.”
Identity
Type,- Upstream pg_settings type
Context,- Takes effect after configuration reload
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- -1 kB
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG9.4 |
| Present in | PG9.4–19 Beta 3 |
| Removed in | No |
| Introduction commit | 8693559cacf1 — New autovacuum_work_mem parameter |
| Commit date | 2013-12-12 |
| Discussion | — |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG9.4–19 Beta 3 | -1 |
kB |
-1 kB |
How it works
autovacuum_work_mem applies separately to each autovacuum worker process. The default sentinel -1 means to use maintenance_work_mem rather than negative memory.
The setting affects autovacuum workers only; it does not change manually issued VACUUM. It is a SIGHUP-context parameter, so it is configured at server level rather than as a per-session tuning knob.
Because multiple workers can run concurrently, the aggregate potential allocation is the per-worker value multiplied by active autovacuum workers. Memory is only one part of vacuum behavior; I/O throttling, worker count, thresholds, and table activity also matter.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | When maintenance_work_mem is large, set an explicit lower autovacuum ceiling unless the concurrent-worker budget clearly fits. Watch vacuum duration, dead-tuple backlog, and latency before increasing it. |
| OLAP | Large relations may justify more memory per worker, but schedule and worker concurrency can dominate. Coordinate the value with autovacuum_max_workers and the maintenance window. |
| Small nodes | Keep -1 only when maintenance_work_mem is itself conservative; otherwise set a smaller explicit value to prevent several workers from exhausting the host. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG9.4–19 Beta 3 unmodified; OLAP: PG9.4–19 Beta 3 unmodified; CRIT: PG9.4–19 Beta 3 unmodified; TINY: PG9.4–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Reading -1 as a literal negative kilobyte value instead of an inheritance sentinel.
- Assuming the setting controls manual VACUUM.
- Budgeting one worker while several autovacuum workers can run at once.
- Increasing memory to address a vacuum problem actually caused by I/O throttling, thresholds, locks, or insufficient worker capacity.
Related parameters
maintenance_work_mem · autovacuum_max_workers · autovacuum_worker_slots · vacuum_buffer_usage_limit · autovacuum_vacuum_cost_delay
References
2 - backend_flush_after
Fact — official short description: “Number of pages after which previously performed writes are flushed to disk.”
Identity
Type,- Upstream pg_settings type
Context,- Settable by an ordinary user
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 0 B (0 × 8kB)
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG9.6 |
| Present in | PG9.6–19 Beta 3 |
| Removed in | No |
| Introduction commit | 428b1d6b29ca — Allow to trigger kernel writeback after a configurable number of writes. |
| Commit date | 2016-02-19 |
| Discussion | — |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG9.6–19 Beta 3 | 0 |
8kB |
0 B (0 × 8kB) |
How it works
After one backend has written more than backend_flush_after bytes, PostgreSQL asks the operating system to begin writing those dirty page-cache pages toward storage. Zero disables these writeback hints.
This is not fsync and does not make a transaction durable earlier. Its aim is to limit large dirty-page bursts and later stalls; support and effect depend on the operating system.
The threshold applies independently to each backend, so concurrent bulk writers can each generate writeback. It complements bgwriter_flush_after and checkpoint_flush_after, which cover different writer processes. Its user context permits session- or transaction-local changes; newly performed or newly planned work sees the value.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Change backend_flush_after only after identifying the corresponding resource bottleneck under concurrency. Budget total memory, I/O, disk, or kernel capacity rather than optimizing one process in isolation. |
| OLAP | Benchmark backend_flush_after with representative bulk and scan phases. Include sustained throughput, spill/writeback, and interference with other sessions, not only one operation’s elapsed time. |
| Small nodes | Keep backend_flush_after conservative on a small host and prefer the upstream default when evidence is weak. A setting copied from a large server can consume a disproportionate share of resources. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG9.6–19 Beta 3 unmodified; OLAP: PG9.6–19 Beta 3 unmodified; CRIT: PG9.6–19 Beta 3 unmodified; TINY: PG9.6–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Changing backend_flush_after without applying its documented unit and configuration context.
- Optimizing an isolated benchmark while ignoring concurrent aggregate resource use.
- Assuming a configured value guarantees operating-system or storage behavior.
- Failing to retest startup, failover, and workload latency after the change.
Related parameters
bgwriter_flush_after · checkpoint_flush_after · bgwriter_delay · shared_buffers · track_io_timing
References
3 - bgwriter_delay
Fact — official short description: “Background writer sleep time between rounds.”
Identity
Type,- Upstream pg_settings type
Context,- Takes effect after configuration reload
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 200 ms
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG9.0 (research boundary) |
| Present in | PG9.0–19 Beta 3 |
| Removed in | No |
| Introduction commit | Not asserted: predates the PG9.0 research boundary |
| Commit date | — |
| Discussion | — |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG9.0–19 Beta 3 | 200 |
ms |
200 ms |
How it works
The background writer performs a round, writes selected dirty shared buffers, then sleeps for bgwriter_delay. When no dirty buffers are found it can enter a longer sleep regardless of this value.
A shorter interval reacts sooner to buffer demand but wakes the process more often. Effective timer granularity can be about 10 ms on some systems, so smaller or non-multiple values may round up in practice.
The number of pages considered per round is derived from recent buffer allocation demand, bgwriter_lru_multiplier, and bgwriter_lru_maxpages; checkpoints are handled separately. Its SIGHUP context allows configuration reload without a server restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Tune bgwriter_delay only with bgwriter and checkpoint metrics. The goal is fewer backend writes and smoother latency without excessive repeated writes; change one dimension at a time. |
| OLAP | Bulk writes can reach bgwriter_delay limits continuously. Measure total bytes written, checkpoints, and storage queueing, not just foreground query latency. |
| Small nodes | A small host usually needs conservative write smoothing. Aggressive bgwriter_delay can consume I/O needed by foreground work, so retain the default unless backend writes are a measured problem. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | 10ms |
different | 10ms |
| OLAP | 10ms |
different | 10ms |
| CRIT | 10ms |
different | 10ms |
| TINY | 10ms |
different | 10ms |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG9.0–19 Beta 3 = 10ms (dcs); OLAP: PG9.0–19 Beta 3 = 10ms (dcs); CRIT: PG9.0–19 Beta 3 = 10ms (dcs); TINY: PG9.0–19 Beta 3 = 10ms (dcs). Advice, pending human review — Editorial inference, pending maintainer review: The 10ms interval is intended to make the background writer inspect dirty-buffer demand much more frequently than PostgreSQL’s boot default.
Common pitfalls
- Changing bgwriter_delay without applying its documented unit and configuration context.
- Optimizing an isolated benchmark while ignoring concurrent aggregate resource use.
- Assuming a configured value guarantees operating-system or storage behavior.
- Failing to retest startup, failover, and workload latency after the change.
Related parameters
bgwriter_lru_maxpages · bgwriter_lru_multiplier · bgwriter_flush_after · shared_buffers · checkpoint_completion_target
References
4 - bgwriter_flush_after
Fact — official short description: “Number of pages after which previously performed writes are flushed to disk.”
Identity
Type,- Upstream pg_settings type
Context,- Takes effect after configuration reload
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 512 KiB (64 × 8kB)
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG9.6 |
| Present in | PG9.6–19 Beta 3 |
| Removed in | No |
| Introduction commit | 428b1d6b29ca — Allow to trigger kernel writeback after a configurable number of writes. |
| Commit date | 2016-02-19 |
| Discussion | — |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG9.6–19 Beta 3 | 64 |
8kB |
512 KiB (64 × 8kB) |
How it works
After the background writer has written more than bgwriter_flush_after bytes, PostgreSQL asks the operating system to begin writing those page-cache pages toward storage. Zero disables the request.
The request is writeback smoothing, not a durability fsync. It can reduce large kernel flush stalls, but can also hurt workloads that benefit from retaining dirty data in the OS cache, and it has no effect on unsupported platforms.
The measured Docker/Linux boot value represents Linux behavior; PostgreSQL documents a platform-dependent default of 512kB on Linux and zero elsewhere. Backend and checkpointer writeback have separate thresholds. Its SIGHUP context allows configuration reload without a server restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Tune bgwriter_flush_after only with bgwriter and checkpoint metrics. The goal is fewer backend writes and smoother latency without excessive repeated writes; change one dimension at a time. |
| OLAP | Bulk writes can reach bgwriter_flush_after limits continuously. Measure total bytes written, checkpoints, and storage queueing, not just foreground query latency. |
| Small nodes | A small host usually needs conservative write smoothing. Aggressive bgwriter_flush_after can consume I/O needed by foreground work, so retain the default unless backend writes are a measured problem. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG9.6–19 Beta 3 unmodified; OLAP: PG9.6–19 Beta 3 unmodified; CRIT: PG9.6–19 Beta 3 unmodified; TINY: PG9.6–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Changing bgwriter_flush_after without applying its documented unit and configuration context.
- Optimizing an isolated benchmark while ignoring concurrent aggregate resource use.
- Assuming a configured value guarantees operating-system or storage behavior.
- Failing to retest startup, failover, and workload latency after the change.
Related parameters
backend_flush_after · checkpoint_flush_after · bgwriter_delay · bgwriter_lru_maxpages · shared_buffers
References
5 - bgwriter_lru_maxpages
Fact — official short description: “Background writer maximum number of LRU pages to flush per round.”
Identity
Type,- Upstream pg_settings type
Context,- Takes effect after configuration reload
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 100
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG9.0 (research boundary) |
| Present in | PG9.0–19 Beta 3 |
| Removed in | No |
| Introduction commit | Not asserted: predates the PG9.0 research boundary |
| Commit date | — |
| Discussion | — |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG9.0–19 Beta 3 | 100 |
— | 100 |
How it works
bgwriter_lru_maxpages caps how many LRU-selected dirty buffers the background writer writes in one round. Zero disables this background-writing activity but does not disable checkpoints.
The writer tries to create enough clean reusable buffers for predicted demand, but this cap bounds each round. If it is reached repeatedly, foreground backends may still have to write buffers themselves.
The prediction comes from recent allocations multiplied by bgwriter_lru_multiplier, and rounds are separated by bgwriter_delay. Raising the cap can smooth latency at the cost of extra write amplification. Its SIGHUP context allows configuration reload without a server restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Tune bgwriter_lru_maxpages only with bgwriter and checkpoint metrics. The goal is fewer backend writes and smoother latency without excessive repeated writes; change one dimension at a time. |
| OLAP | Bulk writes can reach bgwriter_lru_maxpages limits continuously. Measure total bytes written, checkpoints, and storage queueing, not just foreground query latency. |
| Small nodes | A small host usually needs conservative write smoothing. Aggressive bgwriter_lru_maxpages can consume I/O needed by foreground work, so retain the default unless backend writes are a measured problem. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | 800 |
different | 800 |
| OLAP | 800 |
different | 800 |
| CRIT | 800 |
different | 800 |
| TINY | 800 |
different | 800 |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG9.0–19 Beta 3 = 800 (dcs); OLAP: PG9.0–19 Beta 3 = 800 (dcs); CRIT: PG9.0–19 Beta 3 = 800 (dcs); TINY: PG9.0–19 Beta 3 = 800 (dcs). Advice, pending human review — Editorial inference, pending maintainer review: The higher per-round cap is intended to give the frequently running background writer enough capacity to prepare clean buffers instead of forcing foreground backends to write them.
Common pitfalls
- Changing bgwriter_lru_maxpages without applying its documented unit and configuration context.
- Optimizing an isolated benchmark while ignoring concurrent aggregate resource use.
- Assuming a configured value guarantees operating-system or storage behavior.
- Failing to retest startup, failover, and workload latency after the change.
Related parameters
bgwriter_lru_multiplier · bgwriter_delay · bgwriter_flush_after · shared_buffers · checkpoint_completion_target
References
6 - bgwriter_lru_multiplier
Fact — official short description: “Multiple of the average buffer usage to free per round.”
Identity
Type,- Upstream pg_settings type
Context,- Takes effect after configuration reload
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 2
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG9.0 (research boundary) |
| Present in | PG9.0–19 Beta 3 |
| Removed in | No |
| Introduction commit | Not asserted: predates the PG9.0 research boundary |
| Commit date | — |
| Discussion | — |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG9.0–19 Beta 3 | 2 |
— | 2 |
How it works
The background writer averages recent buffer allocations and multiplies that demand by bgwriter_lru_multiplier to choose a target number of clean reusable buffers. A value above 1 adds cushion for bursts.
This is a forecast multiplier, not a direct number of pages. Actual writes remain capped by bgwriter_lru_maxpages and occur once per bgwriter_delay round.
More cushion can reduce foreground backend writes and latency spikes, but pages dirtied repeatedly between checkpoints may be written more times, increasing total I/O. Its SIGHUP context allows configuration reload without a server restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Tune bgwriter_lru_multiplier only with bgwriter and checkpoint metrics. The goal is fewer backend writes and smoother latency without excessive repeated writes; change one dimension at a time. |
| OLAP | Bulk writes can reach bgwriter_lru_multiplier limits continuously. Measure total bytes written, checkpoints, and storage queueing, not just foreground query latency. |
| Small nodes | A small host usually needs conservative write smoothing. Aggressive bgwriter_lru_multiplier can consume I/O needed by foreground work, so retain the default unless backend writes are a measured problem. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | 5.0 |
different | 5.0 |
| OLAP | 5.0 |
different | 5.0 |
| CRIT | 5.0 |
different | 5.0 |
| TINY | 5.0 |
different | 5.0 |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG9.0–19 Beta 3 = 5.0 (dcs); OLAP: PG9.0–19 Beta 3 = 5.0 (dcs); CRIT: PG9.0–19 Beta 3 = 5.0 (dcs); TINY: PG9.0–19 Beta 3 = 5.0 (dcs). Advice, pending human review — Editorial inference, pending maintainer review: The larger forecast cushion is intended to absorb bursts in buffer demand, accepting possible extra background writes.
Common pitfalls
- Changing bgwriter_lru_multiplier without applying its documented unit and configuration context.
- Optimizing an isolated benchmark while ignoring concurrent aggregate resource use.
- Assuming a configured value guarantees operating-system or storage behavior.
- Failing to retest startup, failover, and workload latency after the change.
Related parameters
bgwriter_lru_maxpages · bgwriter_delay · bgwriter_flush_after · shared_buffers · checkpoint_completion_target
References
7 - commit_timestamp_buffers
Fact — official short description: “Sets the size of the dedicated buffer pool used for the commit timestamp cache.”
Identity
Type,- Upstream pg_settings type
Context,- Requires a server restart
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 0 B (0 × 8kB)
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG17 |
| Present in | PG17–19 Beta 3 |
| Removed in | No |
| Introduction commit | 53c2a97a9266 — Improve performance of subsystems on top of SLRU |
| Commit date | 2024-02-28 |
| Discussion | thread 1 · thread 2 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG17–19 Beta 3 | 0 |
8kB |
0 B (0 × 8kB) |
How it works
commit_timestamp_buffers allocates a dedicated startup-time shared buffer pool for pages in pg_commit_ts, the SLRU area used when commit timestamp tracking is enabled.
A configured zero is an automatic sizing request, not zero memory: PostgreSQL derives shared_buffers/512, clamps it to at least 16 and at most 1024 blocks, and allocates the result at server start.
The cache can reduce pg_commit_ts reads but does not enable commit timestamp collection; track_commit_timestamp is the separate functional switch. Increasing it consumes real shared memory. Its postmaster context fixes the value at server start; changing it requires a restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Leave commit_timestamp_buffers at automatic or upstream sizing unless SLRU-specific I/O and contention prove this cache is undersized. A larger number consumes shared memory for the entire server lifetime. |
| OLAP | Analytical workload labels alone do not justify changing commit_timestamp_buffers; tune only when the underlying transaction-state facility, not table scans, is the measured bottleneck. |
| Small nodes | Keep commit_timestamp_buffers at its default on a small host. Moving scarce shared memory into an internal cache without direct evidence can reduce room for more valuable caches and processes. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG17–19 Beta 3 unmodified; OLAP: PG17–19 Beta 3 unmodified; CRIT: PG17–19 Beta 3 unmodified; TINY: PG17–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Changing commit_timestamp_buffers without applying its documented unit and configuration context.
- Optimizing an isolated benchmark while ignoring concurrent aggregate resource use.
- Assuming a configured value guarantees operating-system or storage behavior.
- Failing to retest startup, failover, and workload latency after the change.
Related parameters
track_commit_timestamp · shared_buffers · transaction_buffers · subtransaction_buffers
References
8 - dynamic_shared_memory_type
Fact — official short description: “Selects the dynamic shared memory implementation used.”
Identity
Type,- Upstream pg_settings type
Context,- Requires a server restart
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- posix
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG9.4 |
| Present in | PG9.4–19 Beta 3 |
| Removed in | No |
| Introduction commit | 0ac5e5a7e152 — Allow dynamic allocation of shared memory segments. |
| Commit date | 2013-10-09 |
| Discussion | — |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG9.4–19 Beta 3 | posix |
— | posix |
How it works
dynamic_shared_memory_type selects how PostgreSQL creates dynamic shared memory segments used by parallel query and extensions: POSIX, System V, Windows, or file-backed mmap where supported.
The available enum values and selected boot default are platform dependent. The Docker/Linux catalog reports posix; that is not a portable promise for Windows or systems lacking POSIX shared memory.
The mmap implementation stores mapped files under pg_dynshmem and is generally discouraged because dirty pages may be written repeatedly. min_dynamic_shared_memory can preallocate part of parallel-query memory in the main shared region. Its postmaster context fixes the value at server start; changing it requires a restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Keep the platform’s first supported default, normally posix on the measured Linux images. Change only to solve an API availability or diagnostic requirement, and restart-test parallel query plus extension workers on the target OS. |
| OLAP | Parallel queries use dynamic segments heavily, but choose the implementation by OS support and allocation behavior, not scan throughput alone. Avoid file-backed mmap on ordinary disk because repeated writeback can add I/O; a RAM disk is a special diagnostic case. |
| Small nodes | Keep the platform default. sysv may need kernel tuning, and file-backed mmap can turn memory traffic into disk I/O; neither is a free way to reduce memory use. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG9.4–19 Beta 3 unmodified; OLAP: PG9.4–19 Beta 3 unmodified; CRIT: PG9.4–19 Beta 3 unmodified; TINY: PG9.4–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Treating the Linux-Docker posix boot value as portable to platforms without POSIX shared memory.
- Using file-backed mmap on ordinary storage and creating repeated dirty-page writeback.
- Selecting sysv without checking System V segment limits.
- Confusing dynamic segments with the main region selected by shared_memory_type.
- Changing the startup setting without testing parallel queries and extensions that allocate DSM.
Related parameters
shared_memory_type · min_dynamic_shared_memory · max_parallel_workers · max_worker_processes · huge_pages
References
9 - effective_io_concurrency
Fact — official short description: “Number of simultaneous requests that can be handled efficiently by the disk subsystem.”
Identity
Type,- Upstream pg_settings type
Context,- Settable by an ordinary user
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 16
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG9.0 (research boundary) |
| Present in | PG9.0–19 Beta 3 |
| Removed in | No |
| Introduction commit | Not asserted: predates the PG9.0 research boundary |
| Commit date | — |
| Discussion | — |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG9.0–17 | 1 |
— | 1 |
| PG18–19 Beta 3 | 16 |
— | 16 |
How it works
effective_io_concurrency tells one session how much storage concurrency it should try to exploit; it is not a cluster-wide queue cap. A tablespace option of the same name can override the session setting for data on that storage.
In PG10–17 it mainly controls prefetch distance for supported paths and platforms. The measured Linux-Docker boot value is 1, but unsupported platforms without effective posix_fadvise used 0 as the default; that platform condition must accompany any historical default claim.
PostgreSQL 18 integrates the setting with core asynchronous I/O, uses a boot default of 16, and allows 0 to disable asynchronous requests governed by this target. io_max_concurrency remains the separate per-process execution ceiling, and combine limits control bytes per request.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Start conservatively and measure read latency under concurrency. Fast point queries often gain less than bitmap or scan-heavy workloads, while a very high per-session value can multiply queue depth at high connection counts. |
| OLAP | Analytical scans and bitmap heap scans are stronger candidates for higher values. Benchmark sustained throughput and tail latency together, especially on network or high-IOPS storage. |
| Small nodes | Use the PG18 default or a modest value unless measurements show I/O stalls. A value of 200 is rarely justified on a small host merely because the disk is labeled SSD. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | 200 |
different | 200 |
| OLAP | 200 |
different | 200 |
| CRIT | 200 |
different | 200 |
| TINY | 200 |
different | 200 |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG9.0–19 Beta 3 = 200 (dcs); OLAP: PG9.0–19 Beta 3 = 200 (dcs); CRIT: PG9.0–19 Beta 3 = 200 (dcs); TINY: PG9.0–19 Beta 3 = 200 (dcs). Advice, pending human review — Editorial inference: Pigsty’s SSD branch assumes deep per-session read concurrency and prefetch are beneficial; that assumption requires device-level validation.
Common pitfalls
- Treating this per-session target as a cluster-wide cap; many sessions can multiply outstanding I/O.
- Calling 1 the unconditional PG10–17 upstream default even though unsupported platforms defaulted to 0.
- Applying PG18 AIO behavior to older releases that used the setting chiefly for prefetch advice.
- Using one global value for mixed-storage tablespaces instead of considering tablespace overrides.
- Raising the target until device queueing increases latency for every session.
Related parameters
maintenance_io_concurrency · io_method · io_max_concurrency · io_combine_limit · random_page_cost · effective_cache_size
References
10 - file_copy_method
Fact — official short description: “Selects the file copy method.”
Identity
Type,- Upstream pg_settings type
Context,- Settable by an ordinary user
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- copy
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG18 |
| Present in | PG18–19 Beta 3 |
| Removed in | No |
| Introduction commit | f78ca6f3ebbb — Introduce file_copy_method setting. |
| Commit date | 2025-04-08 |
| Discussion | thread 1 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG18–19 Beta 3 | copy |
— | copy |
How it works
file_copy_method chooses COPY or CLONE for CREATE DATABASE … STRATEGY=FILE_COPY and ALTER DATABASE … SET TABLESPACE. It does not change SQL COPY or general file reads.
CLONE uses copy_file_range() on Linux/FreeBSD or copyfile on macOS, allowing supporting file systems to share blocks or offload the operation. Availability and the actual optimization depend on the operating system and file system; selecting CLONE does not prove that blocks were shared.
Copy-on-write can make the initial operation fast, but later writes allocate private blocks and snapshots still share failure domains. Backup, quota, and free-space accounting must understand the file system semantics. Its user context permits session- or transaction-local changes; newly performed or newly planned work sees the value.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Use COPY as the compatibility baseline. Select CLONE only after CREATE DATABASE … STRATEGY=FILE_COPY and ALTER DATABASE … SET TABLESPACE are tested on the exact kernel and file system, including backup, quota, and free-space monitoring. |
| OLAP | Workload type does not determine the method; clone support and copy-on-write behavior do. CLONE can shorten large database copies, but benchmark the initial operation and subsequent write amplification before standardizing it. |
| Small nodes | Prefer COPY unless the file system’s clone semantics are known and operational tooling understands shared extents. A fast initial clone can still create later space pressure on a small volume. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | clone |
different | clone |
| OLAP | clone |
different | clone |
| CRIT | clone |
different | clone |
| TINY | clone |
different | clone |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG18–19 Beta 3 = clone (dcs); OLAP: PG18–19 Beta 3 = clone (dcs); CRIT: PG18–19 Beta 3 = clone (dcs); TINY: PG18–19 Beta 3 = clone (dcs). Advice, pending human review — Editorial inference, pending maintainer review: The template comment explicitly targets near-instant database cloning on copy-on-write file systems; support and free-space semantics still require deployment validation.
Common pitfalls
- Assuming CLONE guarantees copy-on-write block sharing; the kernel and file system decide the actual optimization.
- Expecting the parameter to affect SQL COPY or ordinary relation reads.
- Ignoring later private-block allocation and free-space pressure after a fast clone.
- Using CLONE before backup, quota, and filesystem tooling understand shared extents.
Related parameters
file_extend_method · data_directory · temp_tablespaces · shared_buffers
References
11 - file_extend_method
Fact — official short description: “Selects the method used for extending data files.”
Identity
Type,- Upstream pg_settings type
Context,- Takes effect after configuration reload
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- posix_fallocate
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG16 |
| Present in | PG16–19 Beta 3 |
| Removed in | No |
| Introduction commit | e37b59802846 — Add file_extend_method=posix_fallocate,write_zeros. |
| Commit date | 2025-05-31 |
| Discussion | thread 1 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG16–19 Beta 3 | posix_fallocate |
— | posix_fallocate |
How it works
file_extend_method chooses how PostgreSQL grows relation files during bulk extension: posix_fallocate when available or explicit zero writes. Extensions of eight blocks or fewer still use zero writes.
The first supported method is platform dependent. posix_fallocate reserves space without writing every block, but unsupported file systems silently fall back; on current BTRFS it can disable compression for the file.
This affects allocation behavior and bulk-write latency, not WAL durability. Storage reservations, sparse-file behavior, compression, and copy-on-write semantics vary by file system. Its SIGHUP context allows configuration reload without a server restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Keep file_extend_method at the detected/default value unless operating-system support and a controlled benchmark justify a change. Validate startup and recovery on the exact kernel and file system. |
| OLAP | Large allocations or bulk I/O can make file_extend_method visible, but platform capability is the first gate. Benchmark on production-equivalent storage and include failure/fallback behavior. |
| Small nodes | Avoid nondefault file_extend_method on a small or heterogeneous fleet unless it solves a verified platform issue. Portability and reliable startup usually outweigh a speculative gain. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG16–19 Beta 3 unmodified; OLAP: PG16–19 Beta 3 unmodified; CRIT: PG16–19 Beta 3 unmodified; TINY: PG16–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Changing file_extend_method without applying its documented unit and configuration context.
- Optimizing an isolated benchmark while ignoring concurrent aggregate resource use.
- Assuming a configured value guarantees operating-system or storage behavior.
- Failing to retest startup, failover, and workload latency after the change.
Related parameters
file_copy_method · backend_flush_after · checkpoint_flush_after · wal_sync_method
References
12 - hash_mem_multiplier
Fact — official short description: “Multiple of “work_mem” to use for hash tables.”
Identity
Type,- Upstream pg_settings type
Context,- Settable by an ordinary user
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 2
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG13 |
| Present in | PG13–19 Beta 3 |
| Removed in | No |
| Introduction commit | 78530c8e7a5a — Add hash_mem_multiplier GUC. |
| Commit date | 2020-07-29 |
| Discussion | thread 1 · thread 2 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG13–14 | 1 |
— | 1 |
| PG15–19 Beta 3 | 2 |
— | 2 |
How it works
The memory ceiling for a hash table is work_mem multiplied by hash_mem_multiplier. It applies to hash joins, hash aggregation, memoize nodes, and other hash-based executor work, but does not enlarge the limit for sort operations.
The parameter first appears in the PG9.0–19 Beta 3 inventory in PostgreSQL 13. Its boot default is 1.0 in PostgreSQL 13–14 and 2.0 from PostgreSQL 15 onward.
A query can contain several hash operations, and parallel workers can execute their own operations, so the product is still an operation-level limit rather than a whole-query memory cap.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Keep the upstream default or make modest increases only after proving recurring hash spills. Evaluate the product with work_mem and peak active plans; do not tune the multiplier in isolation. |
| OLAP | Higher values can help large hash joins and aggregations when memory is genuinely available. Increase under a controlled concurrency ceiling and compare batches, spill volume, and end-to-end runtime. |
| Small nodes | Stay near the default. A high multiplier can turn a seemingly modest work_mem into hundreds of megabytes per hash operation. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | 8.0 |
different | 8.0 |
| OLAP | 8.0 |
different | 8.0 |
| CRIT | 8.0 |
different | 8.0 |
| TINY | 8.0 |
different | 8.0 |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG13–19 Beta 3 = 8.0 (dcs); OLAP: PG13–19 Beta 3 = 8.0 (dcs); CRIT: PG13–19 Beta 3 = 8.0 (dcs); TINY: PG13–19 Beta 3 = 8.0 (dcs). Advice, pending human review — Editorial inference: Pigsty bounds the base work_mem and then gives memory-sensitive hash operations a larger allowance; the resulting per-operation products and parallel concurrency require explicit human review.
Common pitfalls
- Reading the value as an absolute memory size rather than a multiplier of work_mem.
- Forgetting that it has no effect before PostgreSQL 13 and that the upstream default changed in PostgreSQL 15.
- Expecting it to help sorts, which remain governed by work_mem.
- Multiplying only once per query despite multiple hash nodes or parallel workers.
Related parameters
work_mem · temp_file_limit · enable_hashjoin · enable_hashagg · max_parallel_workers_per_gather
References
13 - huge_page_size
Fact — official short description: “The size of huge page that should be requested.”
Identity
Type,- Upstream pg_settings type
Context,- Requires a server restart
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 0 B
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG14 |
| Present in | PG14–19 Beta 3 |
| Removed in | No |
| Introduction commit | d2bddc2500fb — Add huge_page_size setting for use on Linux. |
| Commit date | 2020-07-17 |
| Discussion | thread 1 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG14–19 Beta 3 | 0 |
kB |
0 B |
How it works
huge_page_size selects the explicit huge-page size requested for PostgreSQL’s main shared-memory area when huge_pages is used. Zero means the operating system’s default huge-page size.
This is a startup allocation choice, not an amount of memory. Supported nonzero sizes are architecture and kernel dependent, and PostgreSQL currently supports nondefault selection only on Linux.
The requested page size must match provisioned huge-page pools and the shared-memory allocation. It affects the main shared area, not ordinary backend allocations such as work_mem. Its postmaster context fixes the value at server start; changing it requires a restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Keep 0 so PostgreSQL uses the system’s default explicit huge-page size. Choose a nonzero size only on Linux after provisioning the matching huge-page pool and verifying startup plus huge_pages_status with the intended shared-memory footprint. |
| OLAP | A large main shared-memory region can make page-table savings material, but the useful size depends on architecture, kernel pools, fragmentation, and restart operations—not bulk-I/O throughput. Benchmark the exact host and preserve enough ordinary memory for backends and the OS. |
| Small nodes | Keep 0. A nondefault explicit size adds kernel provisioning and startup-failure risk that rarely pays back on a small shared-memory allocation. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG14–19 Beta 3 unmodified; OLAP: PG14–19 Beta 3 unmodified; CRIT: PG14–19 Beta 3 unmodified; TINY: PG14–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Reading 0 as zero-byte huge pages rather than ‘use the system default huge-page size’.
- Selecting a nonzero size on a non-Linux platform, where nondefault sizes are not supported.
- Requesting a page size whose kernel pool has not been provisioned and causing startup failure when huge_pages=on.
- Confusing explicit huge pages for the main shared-memory area with Transparent Huge Pages or per-backend memory.
Related parameters
huge_pages · huge_pages_status · shared_buffers · shared_memory_type · min_dynamic_shared_memory
References
14 - huge_pages
Fact — official short description: “Use of huge pages on Linux or Windows.”
Identity
Type,- Upstream pg_settings type
Context,- Requires a server restart
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- try
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG9.4 |
| Present in | PG9.4–19 Beta 3 |
| Removed in | No |
| Introduction commit | f8ce16d0d264 — Rename huge_tlb_pages to huge_pages, and improve docs. |
| Commit date | 2014-03-03 |
| Discussion | — |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG9.4–19 Beta 3 | try |
— | try |
How it works
huge_pages affects the main shared-memory area and is evaluated only at server start. try requests huge pages and falls back to normal pages, on makes failure fatal, and off skips the request.
Explicit huge pages can reduce page-table size and CPU time spent on memory management, especially with a large contiguous shared-memory allocation. On Linux, PostgreSQL requires shared_memory_type=mmap and enough pre-provisioned huge pages; huge_pages_status reports the actual outcome.
Explicit HugeTLB pages are not the same as Linux Transparent Huge Pages. PostgreSQL documentation currently discourages THP for some Linux versions even while describing explicit huge pages as potentially beneficial.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Use try while validating operating-system provisioning and huge_pages_status. Switch to on only when failure to obtain huge pages should deliberately block startup and the reservation is managed reliably across reboots. |
| OLAP | Large shared-memory footprints may benefit more, but calculate the required page count and leave memory for backends, query workspaces, and the OS. Benchmark rather than treating huge pages as an automatic throughput win. |
| Small nodes | Leave try or use off when huge-page reservation would create more operational complexity than benefit. Do not reserve a large fraction of a small host without a complete memory budget. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | try |
same as boot | try |
| OLAP | try |
same as boot | try |
| CRIT | try |
same as boot | try |
| TINY | try |
same as boot | try |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG9.4–19 Beta 3 = try (dcs); OLAP: PG9.4–19 Beta 3 = try (dcs); CRIT: PG9.4–19 Beta 3 = try (dcs); TINY: PG9.4–19 Beta 3 = try (dcs). Advice, pending human review — Editorial inference: this preserves opportunistic use when the node is provisioned while keeping startup safe when huge pages are unavailable; OS-level reservation policy must be reviewed separately.
Common pitfalls
- Confusing explicit huge pages with Transparent Huge Pages.
- Setting on before provisioning enough pages, causing PostgreSQL startup to fail.
- Assuming the setting covers work_mem or other ordinary per-process allocations; it targets the main shared-memory area.
- Checking configuration but not the runtime huge_pages_status result.
Related parameters
huge_page_size · huge_pages_status · shared_buffers · shared_memory_type · min_dynamic_shared_memory
References
15 - io_combine_limit
Fact — official short description: “Limit on the size of data reads and writes.”
Identity
Type,- Upstream pg_settings type
Context,- Settable by an ordinary user
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 128 KiB (16 × 8kB)
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG17 |
| Present in | PG17–19 Beta 3 |
| Removed in | No |
| Introduction commit | 210622c60e1a — Provide vectored variant of ReadBuffer(). |
| Commit date | 2024-04-03 |
| Discussion | thread 1 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG17–19 Beta 3 | 16 |
8kB |
128 KiB (16 × 8kB) |
How it works
io_combine_limit limits the byte size of one I/O request formed by combining adjacent eligible operations. It controls bytes per request, not the number of requests that may execute concurrently.
In PostgreSQL 17 it is a standalone user-settable combine-size limit with a measured Linux-Docker boot value of 128kB; io_max_combine_limit does not exist in that release. In PostgreSQL 18, the effective size is the lower of io_combine_limit and the new server-start io_max_combine_limit.
Actual requests can be smaller when adjacent work is unavailable, and operating-system plus BLCKSZ constraints bound the feasible maximum. Its user context permits session- or transaction-local changes; changing it does not alter io_max_concurrency or worker count.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Keep the version-appropriate default until a benchmark shows that combined-request size, rather than queue depth, is a bottleneck. In PG18, verify both io_combine_limit and io_max_combine_limit, and measure tail latency under realistic concurrency. |
| OLAP | Larger combined requests can reduce syscall overhead during eligible sequential work, but may increase service time and reduce fairness. Compare throughput, latency, and actual request sizes; do not infer a useful value from device queue depth alone. |
| Small nodes | Retain 128kB unless measured adjacent I/O shows a benefit from another size. On PG18, raising only io_combine_limit above io_max_combine_limit is ineffective; on PG17 there is no separate clamp GUC. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG17–19 Beta 3 unmodified; OLAP: PG17–19 Beta 3 unmodified; CRIT: PG17–19 Beta 3 unmodified; TINY: PG17–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Applying the PG18 io_max_combine_limit clamp to PostgreSQL 17, where that GUC does not exist.
- Treating a byte-size limit as I/O concurrency or queue depth.
- Raising io_combine_limit above the PG18 server clamp and expecting larger requests.
- Assuming every eligible operation reaches the configured size even when adjacent I/O is unavailable.
Related parameters
io_max_combine_limit · io_max_concurrency · io_method · effective_io_concurrency · maintenance_io_concurrency
References
16 - io_max_combine_limit
Fact — official short description: “Server-wide limit that clamps io_combine_limit.”
Identity
Type,- Upstream pg_settings type
Context,- Requires a server restart
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 128 KiB (16 × 8kB)
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG18 |
| Present in | PG18–19 Beta 3 |
| Removed in | No |
| Introduction commit | 10f664684751 — Introduce io_max_combine_limit. |
| Commit date | 2025-03-19 |
| Discussion | thread 1 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG18–19 Beta 3 | 16 |
8kB |
128 KiB (16 × 8kB) |
How it works
io_max_combine_limit is the server-start ceiling that silently clamps the user-settable io_combine_limit. It protects the I/O subsystem from request sizes beyond the configured server policy.
This controls bytes per combined operation, not queue depth. The feasible maximum depends on operating system and BLCKSZ, typically 1MB on Unix and 128kB on Windows.
Raising io_combine_limit above this value has no effect until this startup parameter is also raised. Combined requests can still be smaller when adjacent work is unavailable. Its postmaster context fixes the value at server start; changing it requires a restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Keep the PG18 server clamp at 128kB unless measurements show that larger combined requests improve eligible I/O without harming latency. Raising it alone changes nothing while io_combine_limit remains lower, and changing it requires a restart. |
| OLAP | A larger clamp merely permits a larger user combine limit; it does not create adjacent I/O or add concurrency. Benchmark actual request sizes, sequential throughput, and mixed-workload fairness with both parameters set intentionally. |
| Small nodes | Retain 128kB on small or mixed-use storage. Do not increase a restart-only global ceiling to fix queue-depth problems, which belong to the concurrency controls. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG18–19 Beta 3 unmodified; OLAP: PG18–19 Beta 3 unmodified; CRIT: PG18–19 Beta 3 unmodified; TINY: PG18–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Treating the server byte-size clamp as an I/O concurrency limit.
- Raising io_max_combine_limit while io_combine_limit remains lower and expecting a change.
- Expecting larger combined requests when adjacent eligible operations do not exist.
- Ignoring operating-system and BLCKSZ limits, especially the smaller typical Windows maximum.
- Forgetting that a change requires a server restart.
Related parameters
io_combine_limit · io_max_concurrency · io_method · shared_buffers
References
17 - io_max_concurrency
Fact — official short description: “Max number of IOs that one process can execute simultaneously.”
Identity
Type,- Upstream pg_settings type
Context,- Requires a server restart
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- -1
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG18 |
| Present in | PG18–19 Beta 3 |
| Removed in | No |
| Introduction commit | 02844012b304 — aio: Basic subsystem initialization |
| Commit date | 2025-03-17 |
| Discussion | thread 1 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG18–19 Beta 3 | -1 |
— | -1 |
How it works
io_max_concurrency is a PostgreSQL 18 server-start ceiling on the number of I/O operations that one process may execute simultaneously. It is per process, not a reservation and not a cluster-wide cap.
The default -1 asks PostgreSQL to derive a value from shared_buffers and configured process maxima, capped at 64. Because many backends and workers can each reach their own ceiling, possible cluster-wide outstanding I/O can be much larger.
effective_io_concurrency and maintenance_io_concurrency are workload targets below this ceiling; io_method chooses the execution mechanism, and combine limits control bytes per request. Changing io_max_concurrency requires a restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Leave -1 until measurements show the automatic per-process ceiling constrains eligible AIO. If setting it explicitly, multiply the value across concurrently active processes and test device queueing plus tail latency after the required restart. |
| OLAP | Raise the per-process ceiling only when one scan or maintenance process cannot keep high-IOPS storage busy and the target-concurrency settings are already appropriate. Compare outstanding-operation counts, throughput, and latency; this parameter does not change request size. |
| Small nodes | Prefer -1. An explicit high ceiling is multiplied by concurrent processes and can overwhelm a small device even though no single process exceeds its configured limit. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG18–19 Beta 3 unmodified; OLAP: PG18–19 Beta 3 unmodified; CRIT: PG18–19 Beta 3 unmodified; TINY: PG18–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Treating the per-process ceiling as a cluster-wide I/O limit.
- Reading -1 as unlimited rather than automatic sizing capped at 64.
- Calling the ceiling reserved capacity; it permits concurrency but does not preallocate I/O slots.
- Confusing operation count with io_combine_limit’s bytes per request.
- Changing the value without a restart or without multiplying exposure across processes.
Related parameters
io_method · io_workers · effective_io_concurrency · maintenance_io_concurrency · io_combine_limit · max_connections
References
18 - io_max_workers
Fact — official short description: “Maximum number of I/O worker processes, for io_method=worker.”
Identity
Type,- Upstream pg_settings type
Context,- Takes effect after configuration reload
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 8
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG19 Beta 3 |
| Present in | PG19 Beta 3 |
| Removed in | No |
| Introduction commit | d1c01b79d4ae — aio: Adjust I/O worker pool automatically. |
| Commit date | 2026-04-08 |
| Discussion | thread 1 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG19 Beta 3 | 8 |
— | 8 |
How it works
PostgreSQL describes io_max_workers as follows: “Maximum number of I/O worker processes, for io_method=worker.” A configuration reload applies the value to the server without a full restart. The atlas measures it in PG19 Beta 3; boot_val is the compiled or initialized baseline, not proof of a running cluster’s effective setting.
These controls govern the elastic background-worker pool used only when io_method is worker. io_min_workers keeps warm capacity, io_max_workers caps the pool, io_worker_launch_interval damps short bursts, and io_worker_idle_timeout lets unused workers retire; they do not raise a backend’s separate io_max_concurrency ceiling.
Read it together with io_min_workers, io_worker_idle_timeout, io_worker_launch_interval, io_method. Check SHOW and pg_settings on the target server, verify the source and pending_restart fields, and compare workload, logs, and resource metrics before and after any change.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Benchmark with the production storage stack and concurrency. Optimize tail latency and queue depth, not only average throughput, and retain capacity for WAL, checkpoints, and foreground reads. |
| OLAP | Use representative scans, prefetch, and spill phases. Increase concurrency or worker capacity only while throughput rises without unacceptable CPU overhead, memory pressure, or storage saturation. |
| Small nodes | Prefer auto or the upstream worker limits. Validate with pg_test_timing or I/O statistics as applicable; a larger pool on a small node can add context switching without useful parallelism. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG19 Beta 3 unmodified; OLAP: PG19 Beta 3 unmodified; CRIT: PG19 Beta 3 unmodified; TINY: PG19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Treating the measured boot_val for io_max_workers as proof of the effective value on an initialized or managed cluster.
- Applying a change as though it were immediate while pg_settings reports sighup context.
- Changing this setting in isolation without checking the linked limits, observability, and rollback path.
- Depending on beta behavior in production without retesting the PostgreSQL 19 final release.
Related parameters
io_min_workers · io_worker_idle_timeout · io_worker_launch_interval · io_method · io_max_concurrency · io_combine_limit
References
19 - io_method
Fact — official short description: “Selects the method for executing asynchronous I/O.”
Identity
Type,- Upstream pg_settings type
Context,- Requires a server restart
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- worker
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG18 |
| Present in | PG18–19 Beta 3 |
| Removed in | No |
| Introduction commit | 02844012b304 — aio: Basic subsystem initialization |
| Commit date | 2025-03-17 |
| Discussion | thread 1 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG18–19 Beta 3 | worker |
— | worker |
How it works
worker sends eligible I/O through dedicated I/O worker processes; io_uring uses Linux io_uring and requires a build with liburing support; sync performs asynchronous-eligible operations synchronously. The upstream default is worker.
The PG18 AIO subsystem allows backends to queue multiple reads and can improve sequential scans, bitmap heap scans, vacuum, and other supported operations. It does not make every PostgreSQL I/O path asynchronous.
io_workers matters only when worker is selected. io_max_concurrency and the I/O combine limits control different dimensions of queue depth and request size, so method selection should be evaluated with them and with the storage stack.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Use worker as the compatibility baseline. Test io_uring only on a verified build and kernel, and keep it only if representative concurrent latency improves without destabilizing the storage queue. |
| OLAP | Sequential and bitmap-heavy analytical workloads are promising AIO candidates. Benchmark worker and io_uring with realistic scan concurrency, not just a single cold scan. |
| Small nodes | Worker is a safe default; sync can be a diagnostic fallback when worker overhead or platform constraints matter. Avoid spending scarce processes on excessive io_workers. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | worker |
same as boot | {{ pg_effective_io_method }} |
| OLAP | worker |
same as boot | {{ pg_effective_io_method }} |
| CRIT | worker |
same as boot | {{ pg_effective_io_method }} |
| TINY | worker |
same as boot | {{ pg_effective_io_method }} |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG18–19 Beta 3 = worker (dcs); OLAP: PG18–19 Beta 3 = worker (dcs); CRIT: PG18–19 Beta 3 = worker (dcs); TINY: PG18–19 Beta 3 = worker (dcs). Advice, pending human review — Editorial hypothesis, pending maintainer review: Pigsty selects the portable PG18 AIO baseline while leaving io_uring as an explicit operator choice.
Common pitfalls
- The parameter does not exist before PostgreSQL 18.
- Changing it requires a server restart.
- io_uring requires operating-system and build support; the enum value alone does not provide that support.
- io_workers has no effect unless io_method=worker.
- AIO benefits only eligible paths and cannot compensate for an overloaded or poorly configured storage layer.
Related parameters
io_workers · io_max_concurrency · io_combine_limit · io_max_combine_limit · effective_io_concurrency · maintenance_io_concurrency
References
20 - io_min_workers
Fact — official short description: “Minimum number of I/O worker processes, for io_method=worker.”
Identity
Type,- Upstream pg_settings type
Context,- Takes effect after configuration reload
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 2
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG19 Beta 3 |
| Present in | PG19 Beta 3 |
| Removed in | No |
| Introduction commit | d1c01b79d4ae — aio: Adjust I/O worker pool automatically. |
| Commit date | 2026-04-08 |
| Discussion | thread 1 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG19 Beta 3 | 2 |
— | 2 |
How it works
PostgreSQL describes io_min_workers as follows: “Minimum number of I/O worker processes, for io_method=worker.” A configuration reload applies the value to the server without a full restart. The atlas measures it in PG19 Beta 3; boot_val is the compiled or initialized baseline, not proof of a running cluster’s effective setting.
These controls govern the elastic background-worker pool used only when io_method is worker. io_min_workers keeps warm capacity, io_max_workers caps the pool, io_worker_launch_interval damps short bursts, and io_worker_idle_timeout lets unused workers retire; they do not raise a backend’s separate io_max_concurrency ceiling.
Read it together with io_max_workers, io_worker_idle_timeout, io_worker_launch_interval, io_method. Check SHOW and pg_settings on the target server, verify the source and pending_restart fields, and compare workload, logs, and resource metrics before and after any change.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Benchmark with the production storage stack and concurrency. Optimize tail latency and queue depth, not only average throughput, and retain capacity for WAL, checkpoints, and foreground reads. |
| OLAP | Use representative scans, prefetch, and spill phases. Increase concurrency or worker capacity only while throughput rises without unacceptable CPU overhead, memory pressure, or storage saturation. |
| Small nodes | Prefer auto or the upstream worker limits. Validate with pg_test_timing or I/O statistics as applicable; a larger pool on a small node can add context switching without useful parallelism. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG19 Beta 3 unmodified; OLAP: PG19 Beta 3 unmodified; CRIT: PG19 Beta 3 unmodified; TINY: PG19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Treating the measured boot_val for io_min_workers as proof of the effective value on an initialized or managed cluster.
- Applying a change as though it were immediate while pg_settings reports sighup context.
- Changing this setting in isolation without checking the linked limits, observability, and rollback path.
- Depending on beta behavior in production without retesting the PostgreSQL 19 final release.
Related parameters
io_max_workers · io_worker_idle_timeout · io_worker_launch_interval · io_method · io_max_concurrency · io_combine_limit
References
21 - io_worker_idle_timeout
Fact — official short description: “Maximum time before idle I/O worker processes time out, for io_method=worker.”
Identity
Type,- Upstream pg_settings type
Context,- Takes effect after configuration reload
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 1 min
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG19 Beta 3 |
| Present in | PG19 Beta 3 |
| Removed in | No |
| Introduction commit | d1c01b79d4ae — aio: Adjust I/O worker pool automatically. |
| Commit date | 2026-04-08 |
| Discussion | thread 1 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG19 Beta 3 | 60000 |
ms |
1 min |
How it works
PostgreSQL describes io_worker_idle_timeout as follows: “Maximum time before idle I/O worker processes time out, for io_method=worker.” A configuration reload applies the value to the server without a full restart. The atlas measures it in PG19 Beta 3; boot_val is the compiled or initialized baseline, not proof of a running cluster’s effective setting.
These controls govern the elastic background-worker pool used only when io_method is worker. io_min_workers keeps warm capacity, io_max_workers caps the pool, io_worker_launch_interval damps short bursts, and io_worker_idle_timeout lets unused workers retire; they do not raise a backend’s separate io_max_concurrency ceiling.
Read it together with io_min_workers, io_max_workers, io_worker_launch_interval, io_method. Check SHOW and pg_settings on the target server, verify the source and pending_restart fields, and compare workload, logs, and resource metrics before and after any change.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Benchmark with the production storage stack and concurrency. Optimize tail latency and queue depth, not only average throughput, and retain capacity for WAL, checkpoints, and foreground reads. |
| OLAP | Use representative scans, prefetch, and spill phases. Increase concurrency or worker capacity only while throughput rises without unacceptable CPU overhead, memory pressure, or storage saturation. |
| Small nodes | Prefer auto or the upstream worker limits. Validate with pg_test_timing or I/O statistics as applicable; a larger pool on a small node can add context switching without useful parallelism. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG19 Beta 3 unmodified; OLAP: PG19 Beta 3 unmodified; CRIT: PG19 Beta 3 unmodified; TINY: PG19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Treating the measured boot_val for io_worker_idle_timeout as proof of the effective value on an initialized or managed cluster.
- Applying a change as though it were immediate while pg_settings reports sighup context.
- Changing this setting in isolation without checking the linked limits, observability, and rollback path.
- Depending on beta behavior in production without retesting the PostgreSQL 19 final release.
Related parameters
io_min_workers · io_max_workers · io_worker_launch_interval · io_method · io_max_concurrency · io_combine_limit
References
22 - io_worker_launch_interval
Fact — official short description: “Minimum time before launching a new I/O worker process, for io_method=worker.”
Identity
Type,- Upstream pg_settings type
Context,- Takes effect after configuration reload
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 100 ms
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG19 Beta 3 |
| Present in | PG19 Beta 3 |
| Removed in | No |
| Introduction commit | d1c01b79d4ae — aio: Adjust I/O worker pool automatically. |
| Commit date | 2026-04-08 |
| Discussion | thread 1 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG19 Beta 3 | 100 |
ms |
100 ms |
How it works
PostgreSQL describes io_worker_launch_interval as follows: “Minimum time before launching a new I/O worker process, for io_method=worker.” A configuration reload applies the value to the server without a full restart. The atlas measures it in PG19 Beta 3; boot_val is the compiled or initialized baseline, not proof of a running cluster’s effective setting.
These controls govern the elastic background-worker pool used only when io_method is worker. io_min_workers keeps warm capacity, io_max_workers caps the pool, io_worker_launch_interval damps short bursts, and io_worker_idle_timeout lets unused workers retire; they do not raise a backend’s separate io_max_concurrency ceiling.
Read it together with io_min_workers, io_max_workers, io_worker_idle_timeout, io_method. Check SHOW and pg_settings on the target server, verify the source and pending_restart fields, and compare workload, logs, and resource metrics before and after any change.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Benchmark with the production storage stack and concurrency. Optimize tail latency and queue depth, not only average throughput, and retain capacity for WAL, checkpoints, and foreground reads. |
| OLAP | Use representative scans, prefetch, and spill phases. Increase concurrency or worker capacity only while throughput rises without unacceptable CPU overhead, memory pressure, or storage saturation. |
| Small nodes | Prefer auto or the upstream worker limits. Validate with pg_test_timing or I/O statistics as applicable; a larger pool on a small node can add context switching without useful parallelism. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG19 Beta 3 unmodified; OLAP: PG19 Beta 3 unmodified; CRIT: PG19 Beta 3 unmodified; TINY: PG19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Treating the measured boot_val for io_worker_launch_interval as proof of the effective value on an initialized or managed cluster.
- Applying a change as though it were immediate while pg_settings reports sighup context.
- Changing this setting in isolation without checking the linked limits, observability, and rollback path.
- Depending on beta behavior in production without retesting the PostgreSQL 19 final release.
Related parameters
io_min_workers · io_max_workers · io_worker_idle_timeout · io_method · io_max_concurrency · io_combine_limit
References
23 - io_workers
Fact — official short description: “Number of IO worker processes, for io_method=worker.”
Identity
Type,- Upstream pg_settings type
Context,- Takes effect after configuration reload
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 3
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG18 |
| Present in | PG18 |
| Removed in | PG19 Beta 3 |
| Introduction commit | 55b454d0e140 — aio: Infrastructure for io_method=worker |
| Commit date | 2025-03-18 |
| Discussion | thread 1 · thread 2 · thread 3 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG18 | 3 |
— | 3 |
How it works
io_workers sets the number of dedicated I/O worker processes used by PostgreSQL 18 when io_method=worker. It has no effect for io_uring or sync.
I/O workers execute asynchronous requests on behalf of database processes; this is an execution pool, distinct from parallel query workers and background worker slots.
Changing the count is reloadable, but useful capacity still depends on io_max_concurrency, workload queue depth, storage latency, and CPU. More workers do not guarantee more device throughput. Its SIGHUP context allows configuration reload without a server restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Tune io_workers only when io_method=worker. Start from the PG18 default 3, measure worker saturation, CPU use, and tail latency, and increase the pool only when queued eligible I/O waits for worker execution rather than for the device. |
| OLAP | Sustained eligible scans can benefit from enough I/O workers to feed storage, but extra processes add scheduling overhead and cannot exceed the per-process or device concurrency bottleneck. Compare throughput and worker utilization; request size is controlled elsewhere. |
| Small nodes | Keep 3 or a measured smaller value when process and CPU budgets are tight. io_workers has no effect under io_uring or sync, so never spend tuning effort on it until io_method is confirmed as worker. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG18; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | 4 |
different | {{ pg_io_workers }} |
| OLAP | 4 |
different | {{ pg_io_workers }} |
| CRIT | 4 |
different | {{ pg_io_workers }} |
| TINY | 3 |
same as boot | {{ pg_io_workers }} |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG18 = 4 (dcs); OLAP: PG18 = 4 (dcs); CRIT: PG18 = 4 (dcs); TINY: PG18 = 3 (dcs). Advice, pending human review — Editorial inference, pending maintainer review: The resolved worker pool gives PG18’s worker AIO method more executors on non-tiny profiles while keeping the tiny profile at the upstream boot count.
Common pitfalls
- Changing io_workers while io_method is io_uring or sync, where it has no effect.
- Treating worker-process count as bytes per request or as the per-process I/O ceiling.
- Adding workers when the storage device, not the worker pool, is already saturated.
- Forgetting that the reloadable pool still consumes process slots, CPU, and scheduling capacity.
Related parameters
io_method · io_max_concurrency · effective_io_concurrency · maintenance_io_concurrency · max_worker_processes
References
24 - logical_decoding_work_mem
Fact — official short description: “Sets the maximum memory to be used for logical decoding.”
Identity
Type,- Upstream pg_settings type
Context,- Settable by an ordinary user
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 64 MiB
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG13 |
| Present in | PG13–19 Beta 3 |
| Removed in | No |
| Introduction commit | cec2edfa7859 — Add logical_decoding_work_mem to limit ReorderBuffer memory usage. |
| Commit date | 2019-11-16 |
| Discussion | thread 1 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG13–19 Beta 3 | 65536 |
kB |
64 MiB |
How it works
logical_decoding_work_mem is the real memory threshold for one logical decoding stream before decoded changes are written to local temporary files. It is independent of ordinary query work_mem.
Each replication connection uses one such buffer, and concurrency is bounded by replication sender capacity rather than client sessions. Large in-progress transactions can spill and later be reread.
Raising the threshold can reduce serialization I/O for logical replication, but the cluster memory budget must multiply it by concurrent decoding streams and include output-plugin memory outside this accounting. Its user context permits session- or transaction-local changes; newly performed or newly planned work sees the value.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Change logical_decoding_work_mem only after identifying the corresponding resource bottleneck under concurrency. Budget total memory, I/O, disk, or kernel capacity rather than optimizing one process in isolation. |
| OLAP | Benchmark logical_decoding_work_mem with representative bulk and scan phases. Include sustained throughput, spill/writeback, and interference with other sessions, not only one operation’s elapsed time. |
| Small nodes | Keep logical_decoding_work_mem conservative on a small host and prefer the upstream default when evidence is weak. A setting copied from a large server can consume a disproportionate share of resources. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG13–19 Beta 3 unmodified; OLAP: PG13–19 Beta 3 unmodified; CRIT: PG13–19 Beta 3 unmodified; TINY: PG13–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Changing logical_decoding_work_mem without applying its documented unit and configuration context.
- Optimizing an isolated benchmark while ignoring concurrent aggregate resource use.
- Assuming a configured value guarantees operating-system or storage behavior.
- Failing to retest startup, failover, and workload latency after the change.
Related parameters
work_mem · max_wal_senders · max_replication_slots · debug_logical_replication_streaming · temp_file_limit
References
25 - maintenance_io_concurrency
Fact — official short description: “A variant of “effective_io_concurrency” that is used for maintenance work.”
Identity
Type,- Upstream pg_settings type
Context,- Settable by an ordinary user
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 16
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG13 |
| Present in | PG13–19 Beta 3 |
| Removed in | No |
| Introduction commit | fc34b0d9de27 — Introduce a maintenance_io_concurrency setting. |
| Commit date | 2020-03-16 |
| Discussion | thread 1 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG13–17 | 10 |
— | 10 |
| PG18–19 Beta 3 | 16 |
— | 16 |
How it works
maintenance_io_concurrency is the per-maintenance-operation target for storage concurrency used by work performed on behalf of many clients. A tablespace option of the same name can override it for that storage; it is neither a cluster-wide device cap nor a memory allocation.
In PG13–17 it chiefly controls maintenance prefetch on supported systems. The measured Linux-Docker boot value is 10, while unsupported platforms without effective prefetch-advice support defaulted to 0; those releases do not have the PG18 core-AIO execution model.
PostgreSQL 18 integrates the target with core AIO and uses a boot default of 16. io_max_concurrency separately clamps simultaneous execution by one process, io_method chooses the execution mechanism, and combine limits control bytes per request. Its user context permits scoped runtime changes.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | For PG13–17, tune this as a maintenance-prefetch target only on supported storage; for PG18, tune it as an AIO concurrency target. Measure foreground tail latency while VACUUM or other eligible maintenance runs, and use a tablespace override for heterogeneous storage. |
| OLAP | Higher maintenance concurrency can shorten eligible scans or vacuum work on high-latency, high-IOPS storage, but it can also deepen the queue seen by analytical queries. Benchmark maintenance completion time and mixed-workload latency together; it does not change request size. |
| Small nodes | Use the version- and platform-appropriate default unless maintenance is demonstrably I/O-stalled. A small host can saturate storage with a low target, so do not copy Pigsty’s SSD value 100 without measurement. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | 100 |
different | 100 |
| OLAP | 100 |
different | 100 |
| CRIT | 100 |
different | 100 |
| TINY | 100 |
different | 100 |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG13–19 Beta 3 = 100 (dcs); OLAP: PG13–19 Beta 3 = 100 (dcs); CRIT: PG13–19 Beta 3 = 100 (dcs); TINY: PG13–19 Beta 3 = 100 (dcs). Advice, pending human review — Editorial inference: the template asks SSD maintenance to exploit more prefetch/AIO concurrency, but the value is a target per maintenance operation and must be validated against foreground latency.
Common pitfalls
- Calling 10 the unconditional PG13–17 default when unsupported platforms used 0.
- Back-projecting PG18 core-AIO semantics into PG13–17 prefetch behavior.
- Treating the per-operation target as a cluster or device-wide cap.
- Confusing concurrency with io_combine_limit’s bytes-per-request dimension.
- Using one value across tablespaces with materially different storage.
Related parameters
effective_io_concurrency · io_method · io_max_concurrency · io_combine_limit · vacuum_buffer_usage_limit
References
26 - maintenance_work_mem
Fact — official short description: “Sets the maximum memory to be used for maintenance operations.”
Identity
Type,- Upstream pg_settings type
Context,- Settable by an ordinary user
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 64 MiB
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG9.0 (research boundary) |
| Present in | PG9.0–19 Beta 3 |
| Removed in | No |
| Introduction commit | Not asserted: predates the PG9.0 research boundary |
| Commit date | — |
| Discussion | — |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG9.0–9.3 | 16384 |
kB |
16 MiB |
| PG9.4–19 Beta 3 | 65536 |
kB |
64 MiB |
How it works
maintenance_work_mem applies to maintenance operations including VACUUM, CREATE INDEX, and ALTER TABLE ADD FOREIGN KEY. Because a session normally runs only one such operation at a time, it can usually be set higher than work_mem.
For parallel utility commands, PostgreSQL treats maintenance_work_mem as a limit for the entire utility command rather than granting the full amount to every parallel maintenance worker. CPU and I/O consumption can still rise with parallelism.
Autovacuum is a separate concurrency concern: when autovacuum_work_mem is -1, each autovacuum worker inherits maintenance_work_mem, so several workers can make the aggregate budget much larger than the single-operation value.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Use enough memory to keep routine vacuum and index work efficient, but budget explicitly for simultaneous autovacuum workers. If interactive latency matters and maintenance_work_mem is large, give autovacuum_work_mem its own lower ceiling. |
| OLAP | Larger values are often useful for index builds, vacuuming large relations, and restores. Schedule heavy maintenance and verify that concurrent maintenance, query memory, and the OS still fit together. |
| Small nodes | Keep the global value modest and temporarily raise it only for controlled maintenance sessions. Check autovacuum inheritance before increasing it. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | 2048MB |
different | {{ pg_maintenance_mem }}MB |
| OLAP | 4096MB |
different | {{ pg_maintenance_mem }}MB |
| CRIT | 2048MB |
different | {{ pg_maintenance_mem }}MB |
| TINY | 2048MB |
different | {{ pg_maintenance_mem }}MB |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG9.0–19 Beta 3 = 2048MB (dcs); OLAP: PG9.0–19 Beta 3 = 4096MB (dcs); CRIT: PG9.0–19 Beta 3 = 2048MB (dcs); TINY: PG9.0–19 Beta 3 = 2048MB (dcs). Advice, pending human review — Editorial inference: the larger OLAP fraction is intended to favor bulk maintenance, while inherited autovacuum exposure needs separate review.
Common pitfalls
- Assuming the value is harmless because maintenance is infrequent while leaving autovacuum_work_mem at -1.
- Multiplying the limit by parallel maintenance workers; PostgreSQL applies it to the utility command as a whole.
- Using a permanently large cluster-wide value for a one-off restore instead of a scoped SET.
- Expecting more memory alone to solve maintenance dominated by locks or storage I/O.
Related parameters
autovacuum_work_mem · autovacuum_max_workers · max_parallel_maintenance_workers · vacuum_buffer_usage_limit · work_mem
References
27 - max_files_per_process
Fact — official short description: “Sets the maximum number of files each server process is allowed to open simultaneously.”
Identity
Type,- Upstream pg_settings type
Context,- Requires a server restart
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 1000
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG9.0 (research boundary) |
| Present in | PG9.0–19 Beta 3 |
| Removed in | No |
| Introduction commit | Not asserted: predates the PG9.0 research boundary |
| Commit date | — |
| Discussion | — |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG9.0–19 Beta 3 | 1000 |
— | 1000 |
How it works
max_files_per_process is PostgreSQL’s startup-time expectation for how many files one server subprocess may keep open, excluding files inherited already open from the postmaster.
It does not raise the kernel’s file-descriptor limit. PostgreSQL uses it in resource management, and on kernels that overcommit descriptors across processes a lower value can prevent system-wide exhaustion.
The relevant capacity is per process multiplied across backends and workers. ‘Too many open files’ can also require fixing OS service limits, connection counts, partition fan-out, or extension behavior. Its postmaster context fixes the value at server start; changing it requires a restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | First compare the PostgreSQL value with the service’s real per-process nofile limit and observed descriptor use. Raising this GUC cannot raise the kernel limit; on systems that overcommit descriptors across many processes, a lower PostgreSQL value can be safer. |
| OLAP | Large partition or index fan-out can increase descriptors in one backend, but size from measured peak opens and the aggregate backend/worker count. Resolve leaks and OS service limits before changing the PostgreSQL ceiling. |
| Small nodes | Keep the default unless descriptor evidence says otherwise. A small host can exhaust the system-wide file table even when every process remains below its individual limit. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG9.0–19 Beta 3 unmodified; OLAP: PG9.0–19 Beta 3 unmodified; CRIT: PG9.0–19 Beta 3 unmodified; TINY: PG9.0–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Expecting the GUC to raise ulimit or the service manager’s nofile limit.
- Sizing only per process and ignoring the aggregate across connections and workers.
- Raising the value to hide a descriptor leak or excessive partition/index fan-out.
- Forgetting that files inherited already open from the postmaster are excluded from this count.
Related parameters
max_connections · max_worker_processes · max_wal_senders · shared_preload_libraries
References
28 - max_notify_queue_pages
Fact — official short description: “Sets the maximum number of allocated pages for NOTIFY / LISTEN queue.”
Identity
Type,- Upstream pg_settings type
Context,- Requires a server restart
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 1048576
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG17 |
| Present in | PG17–19 Beta 3 |
| Removed in | No |
| Introduction commit | 2cdf131c46e6 — Use larger segment file names for pg_notify |
| Commit date | 2023-11-29 |
| Discussion | thread 1 · thread 2 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG17–19 Beta 3 | 1048576 |
— | 1048576 |
How it works
max_notify_queue_pages caps the number of database pages that the disk-backed LISTEN/NOTIFY queue may allocate. At the usual 8kB BLCKSZ, the PG18 default permits up to 8GB.
Notifications remain queued until all listening sessions have consumed or no longer need them. A listener that stays inside a long transaction can prevent cleanup and let queue usage grow.
This is disk capacity, not notify_buffers memory and not a limit on one payload. When the queue is full, transactions attempting NOTIFY can fail at commit. Its postmaster context fixes the value at server start; changing it requires a restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Monitor pg_notification_queue_usage() and identify listeners that remain in long transactions before increasing capacity. Size the disk-backed queue from the maximum tolerated notification backlog and available database volume, not query scan throughput. |
| OLAP | An OLAP label does not justify a larger queue. Long analytical transactions in listening sessions can delay cleanup, so separate listeners from long transactions and measure notification production versus consumption. |
| Small nodes | Keep the default unless the application has a verified LISTEN/NOTIFY backlog requirement. More pages permit more disk consumption and postpone failure; they do not fix a stalled listener. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG17–19 Beta 3 unmodified; OLAP: PG17–19 Beta 3 unmodified; CRIT: PG17–19 Beta 3 unmodified; TINY: PG17–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Increasing queue capacity instead of fixing a listener that stays inside a long transaction.
- Confusing max_notify_queue_pages disk capacity with notify_buffers shared-memory cache.
- Forgetting that, with 8kB pages, the default 1048576 pages permits up to about 8GB.
- Assuming a larger queue changes an individual NOTIFY payload limit or delivery semantics.
Related parameters
notify_buffers · track_activities · max_connections · shared_buffers
References
29 - max_parallel_maintenance_workers
Fact — official short description: “Sets the maximum number of parallel processes per maintenance operation.”
Identity
Type,- Upstream pg_settings type
Context,- Settable by an ordinary user
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 2
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG11 |
| Present in | PG11–19 Beta 3 |
| Removed in | No |
| Introduction commit | 9da0cc35284b — Support parallel btree index builds. |
| Commit date | 2018-02-02 |
| Discussion | thread 1 · thread 2 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG11–19 Beta 3 | 2 |
— | 2 |
How it works
max_parallel_maintenance_workers caps workers requested by one supported maintenance command, such as parallel CREATE INDEX or VACUUM. The leader is additional and may also perform work.
The cap does not reserve workers or guarantee they will be available. Requests compete within max_parallel_workers and max_worker_processes, and operation-specific rules can choose fewer.
Parallel maintenance can multiply CPU and I/O pressure; CREATE INDEX memory follows maintenance-specific accounting rather than simply granting maintenance_work_mem independently to every worker. Its user context permits session- or transaction-local changes; newly performed or newly planned work sees the value.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Set max_parallel_maintenance_workers from a concurrency budget, not core count alone. Protect latency-sensitive OLTP from report and maintenance bursts, and verify actual Workers Planned versus Workers Launched. |
| OLAP | Analytical work can use a larger max_parallel_maintenance_workers, but multiply per-node memory and I/O by concurrent statements. Benchmark throughput under realistic worker contention rather than one isolated query. |
| Small nodes | Keep max_parallel_maintenance_workers conservative on a small host. More possible workers can reduce throughput through context switching and memory pressure even when a single query becomes faster. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | 3 |
different | {{ pg_max_parallel_mt_workers }} |
| OLAP | 3 |
different | {{ pg_max_parallel_mt_workers }} |
| CRIT | 3 |
different | {{ pg_max_parallel_mt_workers }} |
| TINY | 2 |
same as boot | {{ pg_max_parallel_mt_workers }} |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG11–19 Beta 3 = 3 (dcs); OLAP: PG11–19 Beta 3 = 3 (dcs); CRIT: PG11–19 Beta 3 = 3 (dcs); TINY: PG11–19 Beta 3 = 2 (dcs). Advice, pending human review — Editorial inference, pending maintainer review: The profile variables allocate modest parallel maintenance capacity, with one fewer worker in the tiny fixture to reduce resource pressure.
Common pitfalls
- Treating max_parallel_maintenance_workers as reserved capacity rather than an upper bound shared with other work.
- Ignoring that parallel plans multiply CPU, I/O, and work_mem-limited nodes.
- Benchmarking one query without concurrent worker contention.
- Assuming planned workers will always be launched at execution time.
Related parameters
max_parallel_workers · max_worker_processes · maintenance_work_mem · maintenance_io_concurrency · max_parallel_workers_per_gather
References
30 - max_parallel_workers
Fact — official short description: “Sets the maximum number of parallel workers that can be active at one time.”
Identity
Type,- Upstream pg_settings type
Context,- Settable by an ordinary user
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 8
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG10 |
| Present in | PG10–19 Beta 3 |
| Removed in | No |
| Introduction commit | b460f5d66931 — Add max_parallel_workers GUC. |
| Commit date | 2016-12-02 |
| Discussion | — |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG10–19 Beta 3 | 8 |
— | 8 |
How it works
max_parallel_workers caps the cluster-wide number of workers simultaneously active for parallel query and maintenance. It is a pool ceiling beneath max_worker_processes.
Per-operation parameters request workers from this pool, but no slots are reserved. A plan can start with fewer workers than planned, and concurrent jobs can starve each other.
Increasing it expands potential CPU, memory, and I/O concurrency; it does not itself make plans parallel. Planner thresholds, safety checks, and max_parallel_workers_per_gather still govern query choices. Its user context permits session- or transaction-local changes; newly performed or newly planned work sees the value.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Set max_parallel_workers from a concurrency budget, not core count alone. Protect latency-sensitive OLTP from report and maintenance bursts, and verify actual Workers Planned versus Workers Launched. |
| OLAP | Analytical work can use a larger max_parallel_workers, but multiply per-node memory and I/O by concurrent statements. Benchmark throughput under realistic worker contention rather than one isolated query. |
| Small nodes | Keep max_parallel_workers conservative on a small host. More possible workers can reduce throughput through context switching and memory pressure even when a single query becomes faster. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | 4 |
different | {{ pg_max_parallel_workers }} |
| OLAP | 7 |
different | {{ pg_max_parallel_workers }} |
| CRIT | 4 |
different | {{ pg_max_parallel_workers }} |
| TINY | 4 |
different | {{ pg_max_parallel_workers }} |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG10–19 Beta 3 = 4 (dcs); OLAP: PG10–19 Beta 3 = 7 (dcs); CRIT: PG10–19 Beta 3 = 4 (dcs); TINY: PG10–19 Beta 3 = 4 (dcs). Advice, pending human review — Editorial inference, pending maintainer review: The resolved pool gives OLAP more cluster-wide parallel capacity than OLTP/crit/tiny, consistent with a throughput-oriented profile.
Common pitfalls
- Treating max_parallel_workers as reserved capacity rather than an upper bound shared with other work.
- Ignoring that parallel plans multiply CPU, I/O, and work_mem-limited nodes.
- Benchmarking one query without concurrent worker contention.
- Assuming planned workers will always be launched at execution time.
Related parameters
max_worker_processes · max_parallel_workers_per_gather · max_parallel_maintenance_workers · parallel_setup_cost · parallel_leader_participation
References
31 - max_parallel_workers_per_gather
Fact — official short description: “Sets the maximum number of parallel processes per executor node.”
Identity
Type,- Upstream pg_settings type
Context,- Settable by an ordinary user
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 2
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG9.6 |
| Present in | PG9.6–19 Beta 3 |
| Removed in | No |
| Introduction commit | c9ce4a1c61eb — Eliminate “parallel degree” terminology. |
| Commit date | 2016-06-09 |
| Discussion | — |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG9.6 | 0 |
— | 0 |
| PG10–19 Beta 3 | 2 |
— | 2 |
How it works
max_parallel_workers_per_gather limits how many workers one Gather or Gather Merge node may request. Zero prevents parallel query execution through these nodes without disabling other background workers.
Workers are not reserved and can be unavailable at execution time because max_parallel_workers and max_worker_processes are shared pools. The leader process is not included in this numeric limit.
Each parallel plan can multiply work_mem-limited nodes, CPU demand, and I/O. The planner weighs parallel_setup_cost and parallel_tuple_cost before deciding whether to request workers. Its user context permits session- or transaction-local changes; newly performed or newly planned work sees the value.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Set max_parallel_workers_per_gather from a concurrency budget, not core count alone. Protect latency-sensitive OLTP from report and maintenance bursts, and verify actual Workers Planned versus Workers Launched. |
| OLAP | Analytical work can use a larger max_parallel_workers_per_gather, but multiply per-node memory and I/O by concurrent statements. Benchmark throughput under realistic worker contention rather than one isolated query. |
| Small nodes | Keep max_parallel_workers_per_gather conservative on a small host. More possible workers can reduce throughput through context switching and memory pressure even when a single query becomes faster. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | 2 |
same as boot | {{ pg_max_parallel_workers_per_gather|int }} |
| OLAP | 4 |
different | {{ pg_max_parallel_workers_per_gather|int }} |
| CRIT | 0 |
different | {{ pg_max_parallel_workers_per_gather|int }} |
| TINY | 0 |
different | {{ pg_max_parallel_workers_per_gather|int }} |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG9.6–19 Beta 3 = 2 (dcs); OLAP: PG9.6–19 Beta 3 = 4 (dcs); CRIT: PG9.6–19 Beta 3 = 0 (dcs); TINY: PG9.6–19 Beta 3 = 0 (dcs). Advice, pending human review — Editorial inference, pending maintainer review: The values allow modest OLTP and stronger OLAP query parallelism while explicitly suppressing Gather workers in crit and tiny profiles.
Common pitfalls
- Treating max_parallel_workers_per_gather as reserved capacity rather than an upper bound shared with other work.
- Ignoring that parallel plans multiply CPU, I/O, and work_mem-limited nodes.
- Benchmarking one query without concurrent worker contention.
- Assuming planned workers will always be launched at execution time.
Related parameters
max_parallel_workers · max_worker_processes · parallel_setup_cost · parallel_tuple_cost · parallel_leader_participation · work_mem
References
32 - max_prepared_transactions
Fact — official short description: “Sets the maximum number of simultaneously prepared transactions.”
Identity
Type,- Upstream pg_settings type
Context,- Requires a server restart
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 0
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG9.0 (research boundary) |
| Present in | PG9.0–19 Beta 3 |
| Removed in | No |
| Introduction commit | Not asserted: predates the PG9.0 research boundary |
| Commit date | — |
| Discussion | — |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG9.0–19 Beta 3 | 0 |
— | 0 |
How it works
max_prepared_transactions reserves capacity for two-phase transactions left in the prepared state by PREPARE TRANSACTION. Zero disables creating prepared transactions.
Prepared transactions retain locks and transaction state across client disconnects and crashes until COMMIT PREPARED or ROLLBACK PREPARED. Capacity requires shared memory and durable state.
A standby must configure at least the primary’s value or read queries can be refused. This is unrelated to SQL prepared statements and should remain zero unless a two-phase commit coordinator is operationally managed. Its postmaster context fixes the value at server start; changing it requires a restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Keep max_prepared_transactions=0 unless a real two-phase-commit coordinator monitors and resolves every prepared transaction. If enabled, size primary and standbys consistently and alert on transaction age. |
| OLAP | Analytical workload does not justify max_prepared_transactions. Enable only for an application protocol that requires durable prepared transactions, not for SQL prepared statements. |
| Small nodes | Leave max_prepared_transactions=0 on a small deployment unless two-phase commit is mandatory and operational recovery is documented; stranded prepared transactions can block the cluster. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | 0 |
same as boot | {{ pg_max_prepared_transactions }} |
| OLAP | 0 |
same as boot | {{ pg_max_prepared_transactions }} |
| CRIT | 0 |
same as boot | {{ pg_max_prepared_transactions }} |
| TINY | 0 |
same as boot | {{ pg_max_prepared_transactions }} |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG9.0–19 Beta 3 = 0 (dcs); OLAP: PG9.0–19 Beta 3 = 0 (dcs); CRIT: PG9.0–19 Beta 3 = 0 (dcs); TINY: PG9.0–19 Beta 3 = 0 (dcs). Advice, pending human review — Editorial inference, pending maintainer review: The explicit zero keeps two-phase prepared transactions disabled unless the user deliberately changes the profile variable and deploys a coordinator.
Common pitfalls
- Changing max_prepared_transactions without applying its documented unit and configuration context.
- Optimizing an isolated benchmark while ignoring concurrent aggregate resource use.
- Assuming a configured value guarantees operating-system or storage behavior.
- Failing to retest startup, failover, and workload latency after the change.
Related parameters
max_connections · max_locks_per_transaction · wal_level · max_wal_senders
References
33 - max_stack_depth
Fact — official short description: “Sets the maximum stack depth, in kilobytes.”
Identity
Type,- Upstream pg_settings type
Context,- Settable at runtime by a superuser
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 100 KiB
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG9.0 (research boundary) |
| Present in | PG9.0–19 Beta 3 |
| Removed in | No |
| Introduction commit | Not asserted: predates the PG9.0 research boundary |
| Commit date | — |
| Discussion | — |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG9.0–19 Beta 3 | 100 |
kB |
100 KiB |
How it works
max_stack_depth is a guard used by selected recursive execution paths. It neither allocates a process stack nor changes the operating-system stack limit; the kernel limit remains authoritative.
The catalog’s raw boot_val is 100kB in every measured PG9.0–19 Beta 3 image, but the same fresh containers report setting=2048kB, matching the documented 2MB default after configuration/initdb. The 100kB boot fallback must not be presented as the ordinary effective setting.
A safe explicit value is the kernel stack limit, such as ulimit -s, minus roughly 1MB because not every C call site checks depth. Setting it above the real limit can let runaway recursion crash a backend. Its superuser context allows an authorized runtime change without a restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Keep the effective 2MB default unless a reproducible recursive function or expression reaches the PostgreSQL guard. Before raising it, record the service’s real kernel stack limit and preserve about 1MB of safety margin. |
| OLAP | Query duration, table size, and bulk I/O do not justify a larger stack ceiling. Change it only for verified deep expression or function recursion, and test backend stability with the same OS service limits used in production. |
| Small nodes | Do not lower or raise it merely to save memory: the value is a safety check, not reserved memory. Keep the configured default unless the kernel stack and a specific recursive workload prove another value safe and necessary. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG9.0–19 Beta 3 unmodified; OLAP: PG9.0–19 Beta 3 unmodified; CRIT: PG9.0–19 Beta 3 unmodified; TINY: PG9.0–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Confusing boot_val=100kB with the measured and documented effective setting of 2048kB.
- Treating max_stack_depth as allocated memory or a way to reduce resident memory.
- Setting it above the kernel stack limit and allowing recursive code to crash a backend.
- Copying a value across hosts without checking the service manager and ulimit stack settings.
Related parameters
max_worker_processes · shared_buffers · work_mem · max_connections
References
34 - max_worker_processes
Fact — official short description: “Maximum number of concurrent worker processes.”
Identity
Type,- Upstream pg_settings type
Context,- Requires a server restart
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 8
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG9.4 |
| Present in | PG9.4–19 Beta 3 |
| Removed in | No |
| Introduction commit | 6bc8ef0b7f1f — Add new GUC, max_worker_processes, limiting number of bgworkers. |
| Commit date | 2013-07-04 |
| Discussion | — |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG9.4–19 Beta 3 | 8 |
— | 8 |
How it works
max_worker_processes is the startup-time ceiling for concurrent background worker processes, including parallel workers and extension-managed workers. It is broader than max_parallel_workers.
The setting allocates shared control capacity but does not launch workers. Replication, extensions, logical apply, and parallel execution can all depend on slots beneath this ceiling.
A standby should normally configure the same or a higher value than its primary because worker requirements can be replayed or promoted. Increasing it without a CPU and memory budget only creates possible concurrency. Its postmaster context fixes the value at server start; changing it requires a restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Set max_worker_processes from a concurrency budget, not core count alone. Protect latency-sensitive OLTP from report and maintenance bursts, and verify actual Workers Planned versus Workers Launched. |
| OLAP | Analytical work can use a larger max_worker_processes, but multiply per-node memory and I/O by concurrent statements. Benchmark throughput under realistic worker contention rather than one isolated query. |
| Small nodes | Keep max_worker_processes conservative on a small host. More possible workers can reduce throughput through context switching and memory pressure even when a single query becomes faster. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | 24 |
different | {{ pg_max_worker_processes + 8 }} |
| OLAP | 28 |
different | {{ pg_max_worker_processes + 8 }} |
| CRIT | 24 |
different | {{ pg_max_worker_processes + 8 }} |
| TINY | 20 |
different | {{ pg_max_worker_processes + 8 }} |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG9.4–19 Beta 3 = 24 (dcs); OLAP: PG9.4–19 Beta 3 = 28 (dcs); CRIT: PG9.4–19 Beta 3 = 24 (dcs); TINY: PG9.4–19 Beta 3 = 20 (dcs). Advice, pending human review — Editorial inference, pending maintainer review: The template expression adds worker headroom above its profile variable, likely reserving slots for extensions, replication, and parallel work; the exact capacity model needs maintainer confirmation.
Common pitfalls
- Treating max_worker_processes as reserved capacity rather than an upper bound shared with other work.
- Ignoring that parallel plans multiply CPU, I/O, and work_mem-limited nodes.
- Benchmarking one query without concurrent worker contention.
- Assuming planned workers will always be launched at execution time.
Related parameters
max_parallel_workers · max_parallel_workers_per_gather · max_parallel_maintenance_workers · max_logical_replication_workers · max_wal_senders
References
35 - min_dynamic_shared_memory
Fact — official short description: “Amount of dynamic shared memory reserved at startup.”
Identity
Type,- Upstream pg_settings type
Context,- Requires a server restart
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 0 B
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG14 |
| Present in | PG14–19 Beta 3 |
| Removed in | No |
| Introduction commit | 84b1c63ad418 — Preallocate some DSM space at startup. |
| Commit date | 2020-07-31 |
| Discussion | thread 1 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG14–19 Beta 3 | 0 |
MB |
0 B |
How it works
min_dynamic_shared_memory preallocates real memory at server start for parallel-query dynamic shared memory. It is a reserved pool, not a maximum and not an estimate of cache size.
When the pool is insufficient, parallel queries can still allocate temporary dynamic shared memory through dynamic_shared_memory_type, with additional operating-system allocation overhead.
Startup allocation joins the main shared-memory region and can benefit from huge pages where supported. Reserving too much consumes memory even when parallel work is absent. Its postmaster context fixes the value at server start; changing it requires a restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Leave 0 unless repeated parallel-query startup shows measurable dynamic-shared-memory allocation overhead. Any nonzero value is real resident startup memory, so include it in the cluster memory budget even when no parallel query runs. |
| OLAP | Preallocation can reduce temporary DSM setup overhead for frequent concurrent parallel queries. Measure DSM allocation latency and pool use, then reserve only a justified floor; exhaustion still falls back to dynamic allocation. |
| Small nodes | Keep 0 or a small measured reservation. Do not convert speculative future parallel demand into permanently allocated memory on a constrained host. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG14–19 Beta 3 unmodified; OLAP: PG14–19 Beta 3 unmodified; CRIT: PG14–19 Beta 3 unmodified; TINY: PG14–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Treating min_dynamic_shared_memory as a maximum instead of a real preallocated floor.
- Assuming parallel queries fail when the reserved pool is exhausted; PostgreSQL can allocate additional dynamic segments.
- Reserving memory that remains committed even when parallel work is absent.
- Ignoring dynamic_shared_memory_type, huge-page behavior, and the required restart.
Related parameters
dynamic_shared_memory_type · huge_pages · max_parallel_workers · max_parallel_workers_per_gather · shared_buffers
References
36 - multixact_member_buffers
Fact — official short description: “Sets the size of the dedicated buffer pool used for the MultiXact member cache.”
Identity
Type,- Upstream pg_settings type
Context,- Requires a server restart
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 256 KiB (32 × 8kB)
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG17 |
| Present in | PG17–19 Beta 3 |
| Removed in | No |
| Introduction commit | 53c2a97a9266 — Improve performance of subsystems on top of SLRU |
| Commit date | 2024-02-28 |
| Discussion | thread 1 · thread 2 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG17–19 Beta 3 | 32 |
8kB |
256 KiB (32 × 8kB) |
How it works
multixact_member_buffers allocates a dedicated shared buffer pool for pg_multixact/members, which caches MultiXact member entries. This is real startup shared memory, not a planner estimate.
The configured block count is allocated at server start. The unit is BLCKSZ blocks, normally 8kB.
A larger cache can reduce SLRU read/write churn for unusually heavy use of the underlying feature, but it permanently consumes shared memory and does not increase the feature’s logical capacity. Its postmaster context fixes the value at server start; changing it requires a restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Leave multixact_member_buffers at automatic or upstream sizing unless SLRU-specific I/O and contention prove this cache is undersized. A larger number consumes shared memory for the entire server lifetime. |
| OLAP | Analytical workload labels alone do not justify changing multixact_member_buffers; tune only when the underlying transaction-state facility, not table scans, is the measured bottleneck. |
| Small nodes | Keep multixact_member_buffers at its default on a small host. Moving scarce shared memory into an internal cache without direct evidence can reduce room for more valuable caches and processes. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG17–19 Beta 3 unmodified; OLAP: PG17–19 Beta 3 unmodified; CRIT: PG17–19 Beta 3 unmodified; TINY: PG17–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Changing multixact_member_buffers without applying its documented unit and configuration context.
- Optimizing an isolated benchmark while ignoring concurrent aggregate resource use.
- Assuming a configured value guarantees operating-system or storage behavior.
- Failing to retest startup, failover, and workload latency after the change.
Related parameters
multixact_offset_buffers · shared_buffers · max_locks_per_transaction
References
37 - multixact_offset_buffers
Fact — official short description: “Sets the size of the dedicated buffer pool used for the MultiXact offset cache.”
Identity
Type,- Upstream pg_settings type
Context,- Requires a server restart
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 128 KiB (16 × 8kB)
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG17 |
| Present in | PG17–19 Beta 3 |
| Removed in | No |
| Introduction commit | 53c2a97a9266 — Improve performance of subsystems on top of SLRU |
| Commit date | 2024-02-28 |
| Discussion | thread 1 · thread 2 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG17–19 Beta 3 | 16 |
8kB |
128 KiB (16 × 8kB) |
How it works
multixact_offset_buffers allocates a dedicated shared buffer pool for pg_multixact/offsets, which caches MultiXact offsets. This is real startup shared memory, not a planner estimate.
The configured block count is allocated at server start. The unit is BLCKSZ blocks, normally 8kB.
A larger cache can reduce SLRU read/write churn for unusually heavy use of the underlying feature, but it permanently consumes shared memory and does not increase the feature’s logical capacity. Its postmaster context fixes the value at server start; changing it requires a restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Leave multixact_offset_buffers at automatic or upstream sizing unless SLRU-specific I/O and contention prove this cache is undersized. A larger number consumes shared memory for the entire server lifetime. |
| OLAP | Analytical workload labels alone do not justify changing multixact_offset_buffers; tune only when the underlying transaction-state facility, not table scans, is the measured bottleneck. |
| Small nodes | Keep multixact_offset_buffers at its default on a small host. Moving scarce shared memory into an internal cache without direct evidence can reduce room for more valuable caches and processes. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG17–19 Beta 3 unmodified; OLAP: PG17–19 Beta 3 unmodified; CRIT: PG17–19 Beta 3 unmodified; TINY: PG17–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Changing multixact_offset_buffers without applying its documented unit and configuration context.
- Optimizing an isolated benchmark while ignoring concurrent aggregate resource use.
- Assuming a configured value guarantees operating-system or storage behavior.
- Failing to retest startup, failover, and workload latency after the change.
Related parameters
multixact_member_buffers · shared_buffers · max_locks_per_transaction
References
38 - notify_buffers
Fact — official short description: “Sets the size of the dedicated buffer pool used for the LISTEN/NOTIFY message cache.”
Identity
Type,- Upstream pg_settings type
Context,- Requires a server restart
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 128 KiB (16 × 8kB)
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG17 |
| Present in | PG17–19 Beta 3 |
| Removed in | No |
| Introduction commit | 53c2a97a9266 — Improve performance of subsystems on top of SLRU |
| Commit date | 2024-02-28 |
| Discussion | thread 1 · thread 2 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG17–19 Beta 3 | 16 |
8kB |
128 KiB (16 × 8kB) |
How it works
notify_buffers allocates a dedicated shared buffer pool for pg_notify, which caches LISTEN/NOTIFY queue pages. This is real startup shared memory, not a planner estimate.
The configured block count is allocated at server start. The unit is BLCKSZ blocks, normally 8kB.
A larger cache can reduce SLRU read/write churn for unusually heavy use of the underlying feature, but it permanently consumes shared memory and does not increase the feature’s logical capacity. Its postmaster context fixes the value at server start; changing it requires a restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Leave notify_buffers at automatic or upstream sizing unless SLRU-specific I/O and contention prove this cache is undersized. A larger number consumes shared memory for the entire server lifetime. |
| OLAP | Analytical workload labels alone do not justify changing notify_buffers; tune only when the underlying transaction-state facility, not table scans, is the measured bottleneck. |
| Small nodes | Keep notify_buffers at its default on a small host. Moving scarce shared memory into an internal cache without direct evidence can reduce room for more valuable caches and processes. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG17–19 Beta 3 unmodified; OLAP: PG17–19 Beta 3 unmodified; CRIT: PG17–19 Beta 3 unmodified; TINY: PG17–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Changing notify_buffers without applying its documented unit and configuration context.
- Optimizing an isolated benchmark while ignoring concurrent aggregate resource use.
- Assuming a configured value guarantees operating-system or storage behavior.
- Failing to retest startup, failover, and workload latency after the change.
Related parameters
max_notify_queue_pages · shared_buffers · track_activities
References
39 - old_snapshot_threshold
Fact — official short description: “Time before a snapshot is too old to read pages changed after the snapshot was taken.”
Identity
Type,- Upstream pg_settings type
Context,- Requires a server restart
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- -1 min
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG9.6 |
| Present in | PG9.6–16 |
| Removed in | PG17 |
| Introduction commit | 848ef42bb8c7 — Add the “snapshot too old” feature |
| Commit date | 2016-04-08 |
| Discussion | — |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG9.6–16 | -1 |
min |
-1 min |
How it works
old_snapshot_threshold, available through PG16 and removed in PG17, marked snapshots as too old after a configured time so page pruning could proceed more aggressively. A later read could fail with snapshot-too-old rather than return a historical page image.
It was not a transaction timeout: the transaction could continue until it touched data whose old versions had been removed. The feature required startup-time tracking overhead even before a failure appeared.
It did not replace vacuum discipline or prevent all bloat. Because the feature was removed, migration must not carry the parameter into PG17+ and applications must not depend on its error behavior. Its postmaster context fixes the value at server start; changing it requires a restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Do not tune old_snapshot_threshold on current PostgreSQL: remove it from upgrade targets and use the current replacement behavior described above. Retain it only when reproducing the historical version. |
| OLAP | Do not carry old_snapshot_threshold into a modern analytical cluster. Benchmark the supported current mechanisms instead of trying to emulate a removed implementation detail. |
| Small nodes | Delete old_snapshot_threshold during version migration; an unknown-parameter startup failure is more likely than a benefit. Historical test instances should keep the old upstream default. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG16; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG9.6–16 unmodified; OLAP: PG9.6–16 unmodified; CRIT: PG9.6–16 unmodified; TINY: PG9.6–16 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Changing old_snapshot_threshold without applying its documented unit and configuration context.
- Optimizing an isolated benchmark while ignoring concurrent aggregate resource use.
- Assuming a configured value guarantees operating-system or storage behavior.
- Failing to retest startup, failover, and workload latency after the change.
Related parameters
vacuum_defer_cleanup_age · autovacuum · hot_standby_feedback · idle_in_transaction_session_timeout
References
40 - parallel_leader_participation
Fact — official short description: “Controls whether Gather and Gather Merge also run subplans.”
Identity
Type,- Upstream pg_settings type
Context,- Settable by an ordinary user
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- on
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG11 |
| Present in | PG11–19 Beta 3 |
| Removed in | No |
| Introduction commit | e5253fdc4f5f — Add parallel_leader_participation GUC. |
| Commit date | 2017-11-15 |
| Discussion | thread 1 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG11–19 Beta 3 | on |
— | on |
How it works
parallel_leader_participation controls whether the process above Gather or Gather Merge also runs the parallel subplan while coordinating workers. With it off, the leader focuses on reading worker output.
Leader participation can add useful CPU when result production is expensive, but a leader busy executing the subplan may be slower to consume a large worker result stream.
The value is a planning/execution policy for eligible parallel plans, not an extra worker slot. Its effect depends on tuple volume, Gather versus Gather Merge, worker availability, and where the bottleneck lies. Its user context permits session- or transaction-local changes; newly performed or newly planned work sees the value.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Keep the default on unless a representative Gather plan shows that the leader is too busy executing the subplan to consume worker tuples promptly. Test off only at session scope and compare first-row latency, total latency, and worker blocking. |
| OLAP | For CPU-heavy subplans, leader participation often adds useful execution capacity; for very large result streams, disabling it can let the leader drain workers sooner. Compare both boolean states on the same plan and concurrency level. |
| Small nodes | This boolean does not add or remove worker slots. Leave it on unless measurements show a result-consumption bottleneck; size worker counts separately with max_parallel_workers_per_gather and the shared pools. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG11–19 Beta 3 unmodified; OLAP: PG11–19 Beta 3 unmodified; CRIT: PG11–19 Beta 3 unmodified; TINY: PG11–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Treating the boolean as a degree-of-parallelism or worker-count setting.
- Speaking of a ’larger’ value when the only choices are on and off.
- Disabling participation without measuring the extra wait before workers produce the first tuples.
- Enabling participation without checking whether the leader then drains a large worker result stream too slowly.
Related parameters
max_parallel_workers_per_gather · max_parallel_workers · enable_gathermerge · parallel_tuple_cost · parallel_setup_cost
References
41 - replacement_sort_tuples
Fact — official short description: “Sets the maximum number of tuples to be sorted using replacement selection.”
Identity
Type,- Upstream pg_settings type
Context,- Settable by an ordinary user
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 150000
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG9.6 |
| Present in | PG9.6–10 |
| Removed in | PG11 |
| Introduction commit | 0711803775a3 — Use quicksort, not replacement selection, for external sorting. |
| Commit date | 2016-04-08 |
| Discussion | — |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG9.6–10 | 150000 |
— | 150000 |
How it works
In PG10, replacement_sort_tuples selected when an in-memory sort used replacement selection to produce a long initial run for external merge sorting. It was removed in PG11 with the old replacement-selection path.
The value counted tuples, not bytes, so its memory implications depended on row width and work_mem. It was an algorithm threshold rather than a general sort-memory ceiling.
Modern PostgreSQL does not recognize the parameter. Migration should delete it and tune current sort behavior through work_mem, plan shape, and measured temporary-file use instead. Its user context permits session- or transaction-local changes; newly performed or newly planned work sees the value.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Do not tune replacement_sort_tuples on current PostgreSQL: remove it from upgrade targets and use the current replacement behavior described above. Retain it only when reproducing the historical version. |
| OLAP | Do not carry replacement_sort_tuples into a modern analytical cluster. Benchmark the supported current mechanisms instead of trying to emulate a removed implementation detail. |
| Small nodes | Delete replacement_sort_tuples during version migration; an unknown-parameter startup failure is more likely than a benefit. Historical test instances should keep the old upstream default. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG10; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG9.6–10 unmodified; OLAP: PG9.6–10 unmodified; CRIT: PG9.6–10 unmodified; TINY: PG9.6–10 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Changing replacement_sort_tuples without applying its documented unit and configuration context.
- Optimizing an isolated benchmark while ignoring concurrent aggregate resource use.
- Assuming a configured value guarantees operating-system or storage behavior.
- Failing to retest startup, failover, and workload latency after the change.
Related parameters
work_mem · temp_file_limit · enable_sort · trace_sort · log_temp_files
References
42 - serializable_buffers
Fact — official short description: “Sets the size of the dedicated buffer pool used for the serializable transaction cache.”
Identity
Type,- Upstream pg_settings type
Context,- Requires a server restart
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 256 KiB (32 × 8kB)
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG17 |
| Present in | PG17–19 Beta 3 |
| Removed in | No |
| Introduction commit | 53c2a97a9266 — Improve performance of subsystems on top of SLRU |
| Commit date | 2024-02-28 |
| Discussion | thread 1 · thread 2 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG17–19 Beta 3 | 32 |
8kB |
256 KiB (32 × 8kB) |
How it works
serializable_buffers allocates a dedicated shared buffer pool for pg_serial, which caches serializable-transaction state. This is real startup shared memory, not a planner estimate.
The configured block count is allocated at server start. The unit is BLCKSZ blocks, normally 8kB.
A larger cache can reduce SLRU read/write churn for unusually heavy use of the underlying feature, but it permanently consumes shared memory and does not increase the feature’s logical capacity. Its postmaster context fixes the value at server start; changing it requires a restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Leave serializable_buffers at automatic or upstream sizing unless SLRU-specific I/O and contention prove this cache is undersized. A larger number consumes shared memory for the entire server lifetime. |
| OLAP | Analytical workload labels alone do not justify changing serializable_buffers; tune only when the underlying transaction-state facility, not table scans, is the measured bottleneck. |
| Small nodes | Keep serializable_buffers at its default on a small host. Moving scarce shared memory into an internal cache without direct evidence can reduce room for more valuable caches and processes. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG17–19 Beta 3 unmodified; OLAP: PG17–19 Beta 3 unmodified; CRIT: PG17–19 Beta 3 unmodified; TINY: PG17–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Changing serializable_buffers without applying its documented unit and configuration context.
- Optimizing an isolated benchmark while ignoring concurrent aggregate resource use.
- Assuming a configured value guarantees operating-system or storage behavior.
- Failing to retest startup, failover, and workload latency after the change.
Related parameters
shared_buffers · max_connections · max_pred_locks_per_transaction
References
43 - shared_buffers
Fact — official short description: “Sets the number of shared memory buffers used by the server.”
Identity
Type,- Upstream pg_settings type
Context,- Requires a server restart
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 128 MiB (16384 × 8kB)
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG9.0 (research boundary) |
| Present in | PG9.0–19 Beta 3 |
| Removed in | No |
| Introduction commit | Not asserted: predates the PG9.0 research boundary |
| Commit date | — |
| Discussion | — |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG9.0–14 | 1024 |
8kB |
8 MiB (1024 × 8kB) |
| PG15–19 Beta 3 | 16384 |
8kB |
128 MiB (16384 × 8kB) |
How it works
shared_buffers allocates PostgreSQL’s real shared buffer cache at server start. Pages cached here are PostgreSQL-managed and coexist with the operating system page cache; the setting is not merely a planner estimate.
The PG10-14 Docker boot value in this catalog is 8MB while PG15-18 report 128MB, reflecting historical initdb/container defaults rather than a universal hardware recommendation. The official guidance treats about 25% of RAM as a starting point for a dedicated server and rarely expects more than 40% to help.
A larger cache changes checkpoint and WAL pressure, often requiring a larger max_wal_size, and leaves less memory for backend processes, work_mem, maintenance, extensions, and the OS. Buffer allocation uses BLCKSZ units, normally 8kB. Its postmaster context fixes the value at server start; changing it requires a restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Change shared_buffers only after identifying the corresponding resource bottleneck under concurrency. Budget total memory, I/O, disk, or kernel capacity rather than optimizing one process in isolation. |
| OLAP | Benchmark shared_buffers with representative bulk and scan phases. Include sustained throughput, spill/writeback, and interference with other sessions, not only one operation’s elapsed time. |
| Small nodes | Keep shared_buffers conservative on a small host and prefer the upstream default when evidence is weak. A setting copied from a large server can consume a disproportionate share of resources. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | 8192MB |
different | {{ pg_shared_buffers }}MB |
| OLAP | 8192MB |
different | {{ pg_shared_buffers }}MB |
| CRIT | 8192MB |
different | {{ pg_shared_buffers }}MB |
| TINY | 8192MB |
different | {{ pg_shared_buffers }}MB |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG9.0–19 Beta 3 = 8192MB (dcs); OLAP: PG9.0–19 Beta 3 = 8192MB (dcs); CRIT: PG9.0–19 Beta 3 = 8192MB (dcs); TINY: PG9.0–19 Beta 3 = 8192MB (dcs). Advice, pending human review — Editorial inference, pending maintainer review: Pigsty deliberately parameterizes real shared-buffer allocation instead of hard-coding the fixture’s 8192MB; the published rationale must reference the host-memory sizing formula, not present 8192MB as a universal default.
Common pitfalls
- Changing shared_buffers without applying its documented unit and configuration context.
- Optimizing an isolated benchmark while ignoring concurrent aggregate resource use.
- Assuming a configured value guarantees operating-system or storage behavior.
- Failing to retest startup, failover, and workload latency after the change.
Related parameters
effective_cache_size · work_mem · max_wal_size · huge_pages · checkpoint_completion_target · wal_buffers
References
44 - shared_memory_type
Fact — official short description: “Selects the shared memory implementation used for the main shared memory region.”
Identity
Type,- Upstream pg_settings type
Context,- Requires a server restart
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- mmap
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG12 |
| Present in | PG12–19 Beta 3 |
| Removed in | No |
| Introduction commit | f1bebef60ec8 — Add shared_memory_type GUC. |
| Commit date | 2019-02-03 |
| Discussion | thread 1 · thread 2 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG12–19 Beta 3 | mmap |
— | mmap |
How it works
shared_memory_type selects the operating-system mechanism for PostgreSQL’s main shared-memory region, including shared_buffers and other fixed shared state. It does not set the region’s size.
Supported enum values and the first-supported boot default are platform dependent. The Docker/Linux catalog reports mmap; Windows has its own implementation, and sysv can require nondefault kernel limits for large allocations.
On Linux, explicit huge_pages support requires mmap. This parameter is distinct from dynamic_shared_memory_type, which governs temporary dynamic segments used by parallel query and extensions. Its postmaster context fixes the value at server start; changing it requires a restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Keep the first supported platform default; on Linux that is normally mmap and is required for PostgreSQL’s explicit huge-page support. Use sysv only for a verified compatibility need and provision its kernel limits before restart. |
| OLAP | Large shared_buffers increases the importance of reliable main-region allocation, but workload label does not select the API. Validate startup, huge pages, failover, and service limits on the target operating system rather than benchmarking storage throughput. |
| Small nodes | Keep the platform default. Changing the implementation does not reduce the configured shared-memory size and can add kernel-limit or portability failures. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG12–19 Beta 3 unmodified; OLAP: PG12–19 Beta 3 unmodified; CRIT: PG12–19 Beta 3 unmodified; TINY: PG12–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Treating the Linux-Docker mmap boot value as a portable default for every operating system.
- Selecting sysv without raising the System V shared-memory kernel limits needed for the main region.
- Forgetting that explicit huge pages on Linux require shared_memory_type=mmap.
- Expecting the parameter to resize shared_buffers or other shared allocations.
Related parameters
dynamic_shared_memory_type · shared_buffers · huge_pages · huge_page_size · min_dynamic_shared_memory
References
45 - subtransaction_buffers
Fact — official short description: “Sets the size of the dedicated buffer pool used for the subtransaction cache.”
Identity
Type,- Upstream pg_settings type
Context,- Requires a server restart
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 0 B (0 × 8kB)
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG17 |
| Present in | PG17–19 Beta 3 |
| Removed in | No |
| Introduction commit | 53c2a97a9266 — Improve performance of subsystems on top of SLRU |
| Commit date | 2024-02-28 |
| Discussion | thread 1 · thread 2 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG17–19 Beta 3 | 0 |
8kB |
0 B (0 × 8kB) |
How it works
subtransaction_buffers allocates a dedicated shared buffer pool for pg_subtrans, which caches subtransaction parent mappings. This is real startup shared memory, not a planner estimate.
Zero is an automatic-sizing request: PostgreSQL derives shared_buffers/512 and clamps it between 16 and 1024 blocks. The unit is BLCKSZ blocks, normally 8kB.
A larger cache can reduce SLRU read/write churn for unusually heavy use of the underlying feature, but it permanently consumes shared memory and does not increase the feature’s logical capacity. Its postmaster context fixes the value at server start; changing it requires a restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Leave subtransaction_buffers at automatic or upstream sizing unless SLRU-specific I/O and contention prove this cache is undersized. A larger number consumes shared memory for the entire server lifetime. |
| OLAP | Analytical workload labels alone do not justify changing subtransaction_buffers; tune only when the underlying transaction-state facility, not table scans, is the measured bottleneck. |
| Small nodes | Keep subtransaction_buffers at its default on a small host. Moving scarce shared memory into an internal cache without direct evidence can reduce room for more valuable caches and processes. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG17–19 Beta 3 unmodified; OLAP: PG17–19 Beta 3 unmodified; CRIT: PG17–19 Beta 3 unmodified; TINY: PG17–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Changing subtransaction_buffers without applying its documented unit and configuration context.
- Optimizing an isolated benchmark while ignoring concurrent aggregate resource use.
- Assuming a configured value guarantees operating-system or storage behavior.
- Failing to retest startup, failover, and workload latency after the change.
Related parameters
transaction_buffers · shared_buffers · max_locks_per_transaction
References
46 - temp_buffers
Fact — official short description: “Sets the maximum number of temporary buffers used by each session.”
Identity
Type,- Upstream pg_settings type
Context,- Settable by an ordinary user
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 8 MiB (1024 × 8kB)
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG9.0 (research boundary) |
| Present in | PG9.0–19 Beta 3 |
| Removed in | No |
| Introduction commit | Not asserted: predates the PG9.0 research boundary |
| Commit date | — |
| Discussion | — |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG9.0–19 Beta 3 | 1024 |
8kB |
8 MiB (1024 × 8kB) |
How it works
temp_buffers controls session-local buffers for temporary-table access. It does not govern sort or hash spill files created by ordinary query execution.
A session can change the value only before its first use of a temporary table; later SET commands have no effect for that session. Buffers are allocated on demand up to the ceiling.
An unused increase still creates buffer-descriptor overhead, while each buffer actually used consumes one database block, normally 8kB. Aggregate usage therefore depends on the number of sessions actively using temporary tables.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Leave the default unless the application demonstrably uses sizable temporary tables. Prefer scoped changes in the sessions that create them and set the value before first access. |
| OLAP | Raise it only for workflows that use PostgreSQL temporary tables; work_mem, not temp_buffers, is the primary control for sort and hash operations. Include session concurrency in the budget. |
| Small nodes | Keep the default and avoid globally increasing per-session ceilings. Temporary-table-heavy jobs should be isolated or adjusted locally. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG9.0–19 Beta 3 unmodified; OLAP: PG9.0–19 Beta 3 unmodified; CRIT: PG9.0–19 Beta 3 unmodified; TINY: PG9.0–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Confusing temporary-table buffers with sort and hash temporary files.
- Issuing SET after the session has already accessed a temporary table.
- Ignoring multiplication across many sessions actively using temporary tables.
- Assuming a large value is fully allocated immediately; PostgreSQL grows usage on demand, though descriptor overhead remains.
Related parameters
work_mem · temp_file_limit · temp_tablespaces · max_connections · log_temp_files
References
47 - temp_file_limit
Fact — official short description: “Limits the total size of all temporary files used by each process.”
Identity
Type,- Upstream pg_settings type
Context,- Settable at runtime by a superuser
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- -1 kB
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG9.2 |
| Present in | PG9.2–19 Beta 3 |
| Removed in | No |
| Introduction commit | 23e5b16c71f2 — Add temp_file_limit GUC parameter to constrain temporary file space usage. |
| Commit date | 2011-07-17 |
| Discussion | — |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG9.2–19 Beta 3 | -1 |
kB |
-1 kB |
How it works
temp_file_limit limits the total instantaneous size of temporary files owned by one PostgreSQL process, including sort and hash spill files and storage for held cursors. Exceeding it cancels the transaction.
The limit is per process, not cluster-wide, so concurrent backends and parallel workers can collectively consume multiples of it. The default -1 means no limit.
Explicit temporary-table storage is excluded from this limit. log_temp_files and pg_stat_database.temp_bytes observe related temporary-file activity but do not change the enforcement boundary.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Use a finite guardrail sized from filesystem headroom and worst-case concurrent spillers. Monitor temp_bytes and log_temp_files so the cap blocks pathological queries rather than routine bursts. |
| OLAP | Allow a larger but still finite budget for known large joins and sorts, and coordinate it with query concurrency and parallelism. Test cancellation behavior before relying on the limit in production. |
| Small nodes | Choose a modest fraction of the data filesystem and preserve emergency free space. Pair a lower limit with conservative work_mem and query timeouts. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | 5GB |
different | {{ ([pg_size_twentieth, 200])|min }}GB |
| OLAP | 20GB |
different | {{ ([pg_size_twentieth * 4, 2000])|min }}GB |
| CRIT | 5GB |
different | {{ ([pg_size_twentieth, 200])|min }}GB |
| TINY | 5GB |
different | {{ ([pg_size_twentieth, 200])|min }}GB |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG9.2–19 Beta 3 = 5GB (dcs); OLAP: PG9.2–19 Beta 3 = 20GB (dcs); CRIT: PG9.2–19 Beta 3 = 5GB (dcs); TINY: PG9.2–19 Beta 3 = 5GB (dcs). Advice, pending human review — Editorial inference: these values act as process-level circuit breakers while giving analytical spills more room; aggregate multi-process exposure still needs capacity review.
Common pitfalls
- Treating a per-process limit as a cluster-wide disk cap.
- Expecting it to constrain explicit temporary tables, which are excluded.
- Leaving -1 on a filesystem where one runaway query can exhaust shared storage.
- Setting the cap below normal spill sizes and discovering through transaction cancellations.
Related parameters
work_mem · hash_mem_multiplier · log_temp_files · temp_tablespaces · max_parallel_workers_per_gather
References
48 - timing_clock_source
Fact — official short description: “Controls the clock source used for collecting timing measurements.”
Identity
Type,- Upstream pg_settings type
Context,- Settable at runtime by a superuser
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- auto
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG19 Beta 3 |
| Present in | PG19 Beta 3 |
| Removed in | No |
| Introduction commit | 294520c44487 — instrumentation: Use Time-Stamp Counter on x86-64 to lower overhead |
| Commit date | 2026-04-07 |
| Discussion | thread 1 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG19 Beta 3 | auto |
— | auto |
How it works
PostgreSQL describes timing_clock_source as follows: “Controls the clock source used for collecting timing measurements.” It can be changed at run time only by a superuser or a role with an appropriate SET grant. The atlas measures it in PG19 Beta 3; boot_val is the compiled or initialized baseline, not proof of a running cluster’s effective setting.
auto selects a supported x86-64 Time-Stamp Counter when appropriate and otherwise uses the operating-system monotonic clock; system forces the OS clock and tsc requests CPU instructions such as RDTSC/RDTSCP. The faster source lowers EXPLAIN ANALYZE measurement overhead, but emulated or unstable TSC behavior can be slower or invalid.
Read it together with track_io_timing, track_wal_io_timing, log_executor_stats, compute_query_id. Check SHOW and pg_settings on the target server, verify the source and pending_restart fields, and compare workload, logs, and resource metrics before and after any change.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Benchmark with the production storage stack and concurrency. Optimize tail latency and queue depth, not only average throughput, and retain capacity for WAL, checkpoints, and foreground reads. |
| OLAP | Use representative scans, prefetch, and spill phases. Increase concurrency or worker capacity only while throughput rises without unacceptable CPU overhead, memory pressure, or storage saturation. |
| Small nodes | Prefer auto or the upstream worker limits. Validate with pg_test_timing or I/O statistics as applicable; a larger pool on a small node can add context switching without useful parallelism. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG19 Beta 3 unmodified; OLAP: PG19 Beta 3 unmodified; CRIT: PG19 Beta 3 unmodified; TINY: PG19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Treating the measured boot_val for timing_clock_source as proof of the effective value on an initialized or managed cluster.
- Applying a change as though it were immediate while pg_settings reports superuser context.
- Changing this setting in isolation without checking the linked limits, observability, and rollback path.
- Depending on beta behavior in production without retesting the PostgreSQL 19 final release.
Related parameters
track_io_timing · track_wal_io_timing · log_executor_stats · compute_query_id
References
49 - transaction_buffers
Fact — official short description: “Sets the size of the dedicated buffer pool used for the transaction status cache.”
Identity
Type,- Upstream pg_settings type
Context,- Requires a server restart
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 0 B (0 × 8kB)
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG17 |
| Present in | PG17–19 Beta 3 |
| Removed in | No |
| Introduction commit | 53c2a97a9266 — Improve performance of subsystems on top of SLRU |
| Commit date | 2024-02-28 |
| Discussion | thread 1 · thread 2 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG17–19 Beta 3 | 0 |
8kB |
0 B (0 × 8kB) |
How it works
transaction_buffers allocates a dedicated shared buffer pool for pg_xact, which caches transaction commit-status pages. This is real startup shared memory, not a planner estimate.
Zero is an automatic-sizing request: PostgreSQL derives shared_buffers/512 and clamps it between 16 and 1024 blocks. The unit is BLCKSZ blocks, normally 8kB.
A larger cache can reduce SLRU read/write churn for unusually heavy use of the underlying feature, but it permanently consumes shared memory and does not increase the feature’s logical capacity. Its postmaster context fixes the value at server start; changing it requires a restart.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Leave transaction_buffers at automatic or upstream sizing unless SLRU-specific I/O and contention prove this cache is undersized. A larger number consumes shared memory for the entire server lifetime. |
| OLAP | Analytical workload labels alone do not justify changing transaction_buffers; tune only when the underlying transaction-state facility, not table scans, is the measured bottleneck. |
| Small nodes | Keep transaction_buffers at its default on a small host. Moving scarce shared memory into an internal cache without direct evidence can reduce room for more valuable caches and processes. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG17–19 Beta 3 unmodified; OLAP: PG17–19 Beta 3 unmodified; CRIT: PG17–19 Beta 3 unmodified; TINY: PG17–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Changing transaction_buffers without applying its documented unit and configuration context.
- Optimizing an isolated benchmark while ignoring concurrent aggregate resource use.
- Assuming a configured value guarantees operating-system or storage behavior.
- Failing to retest startup, failover, and workload latency after the change.
Related parameters
subtransaction_buffers · shared_buffers · commit_timestamp_buffers
References
50 - vacuum_buffer_usage_limit
Fact — official short description: “Sets the buffer pool size for VACUUM, ANALYZE, and autovacuum.”
Identity
Type,- Upstream pg_settings type
Context,- Settable by an ordinary user
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 2 MiB
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG16 |
| Present in | PG16–19 Beta 3 |
| Removed in | No |
| Introduction commit | 1cbbee033857 — Add VACUUM/ANALYZE BUFFER_USAGE_LIMIT option |
| Commit date | 2023-04-07 |
| Discussion | thread 1 |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG16 | 256 |
kB |
256 KiB |
| PG17–19 Beta 3 | 2048 |
kB |
2 MiB |
How it works
vacuum_buffer_usage_limit sizes the shared-buffer access-strategy ring used by VACUUM, ANALYZE, and autovacuum. It is not a private memory allocation and does not cap all buffers those operations can ever touch.
A nonzero value is silently capped at one eighth of shared_buffers; zero allows unrestricted shared-buffer use. The ring reduces eviction of unrelated hot pages while permitting repeated reuse during scans.
Larger rings can improve maintenance throughput but can displace more useful cache. VACUUM and ANALYZE can override it per command with BUFFER_USAGE_LIMIT, and the boot default rose from 256kB in PG16 to 2MB in PG17. Its user context permits session- or transaction-local changes; newly performed or newly planned work sees the value.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Change vacuum_buffer_usage_limit only after identifying the corresponding resource bottleneck under concurrency. Budget total memory, I/O, disk, or kernel capacity rather than optimizing one process in isolation. |
| OLAP | Benchmark vacuum_buffer_usage_limit with representative bulk and scan phases. Include sustained throughput, spill/writeback, and interference with other sessions, not only one operation’s elapsed time. |
| Small nodes | Keep vacuum_buffer_usage_limit conservative on a small host and prefer the upstream default when evidence is weak. A setting copied from a large server can consume a disproportionate share of resources. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | Unmodified | — | — |
| OLAP | Unmodified | — | — |
| CRIT | Unmodified | — | — |
| TINY | Unmodified | — | — |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG16–19 Beta 3 unmodified; OLAP: PG16–19 Beta 3 unmodified; CRIT: PG16–19 Beta 3 unmodified; TINY: PG16–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.
Common pitfalls
- Changing vacuum_buffer_usage_limit without applying its documented unit and configuration context.
- Optimizing an isolated benchmark while ignoring concurrent aggregate resource use.
- Assuming a configured value guarantees operating-system or storage behavior.
- Failing to retest startup, failover, and workload latency after the change.
Related parameters
shared_buffers · maintenance_work_mem · autovacuum_work_mem · maintenance_io_concurrency · track_io_timing
References
51 - work_mem
Fact — official short description: “Sets the maximum memory to be used for query workspaces.”
Identity
Type,- Upstream pg_settings type
Context,- Settable by an ordinary user
Unit,- Raw unit
Range,- Raw limits in the last observed version
Enum values,- — for non-enum types
Category,- Upstream classification
Latest boot value,- 4 MiB
Lifecycle
| Fact | Value |
|---|---|
| First observed | PG9.0 (research boundary) |
| Present in | PG9.0–19 Beta 3 |
| Removed in | No |
| Introduction commit | Not asserted: predates the PG9.0 research boundary |
| Commit date | — |
| Discussion | — |
Default history
| Versions | Raw boot_val |
Unit | Human value |
|---|---|---|---|
| PG9.0–9.3 | 1024 |
kB |
1 MiB |
| PG9.4–19 Beta 3 | 4096 |
kB |
4 MiB |
How it works
work_mem is a base limit for each execution operation, not a reservation for an entire query or session. A complex plan can run several sorts or hash operations concurrently, and many sessions can do the same, so aggregate memory can be many times the configured value.
Sorts used by ORDER BY, DISTINCT, and merge joins generally use work_mem before spilling. Hash joins, hash aggregation, memoize nodes, and hash-based IN processing derive their limit from work_mem multiplied by hash_mem_multiplier.
Parallel query further multiplies exposure because resource limits such as work_mem apply to individual worker processes. The setting is therefore best understood together with plan shape, parallelism, and active-query concurrency.
Tuning advice
Advice. These are workload-specific starting points and must be validated with measurements.
| Workload | Guidance |
|---|---|
| OLTP | Keep the cluster-wide value conservative and size it against peak active backends, not the connection limit alone. Use transaction-, role-, or database-scoped overrides for known reporting jobs after checking actual spill behavior. |
| OLAP | Larger values can remove expensive sort and hash spills, but raise them with an explicit concurrency budget. Compare EXPLAIN (ANALYZE, BUFFERS) results and temporary-file statistics before and after each change. |
| Small nodes | Prefer the default or a low tens-of-megabytes setting and leave headroom for shared buffers, autovacuum, the operating system, and other processes. A single globally generous value is risky on a small host. |
Pigsty
Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.
| Template | Effective value | Versus upstream boot | Source expression |
|---|---|---|---|
| OLTP | 64MB |
different | {{ pg_workmem }}MB |
| OLAP | 64MB |
different | {{ pg_workmem }}MB |
| CRIT | 64MB |
different | {{ pg_workmem }}MB |
| TINY | 32MB |
different | {{ pg_workmem }}MB |
Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG9.0–19 Beta 3 = 64MB (dcs); OLAP: PG9.0–19 Beta 3 = 64MB (dcs); CRIT: PG9.0–19 Beta 3 = 64MB (dcs); TINY: PG9.0–19 Beta 3 = 32MB (dcs). Advice, pending human review — Editorial inference: the formula is intended to trade spill frequency against worst-case concurrent memory.
Common pitfalls
- Treating work_mem as a per-connection or per-query cap; it is normally available to each eligible plan operation.
- Ignoring parallel workers, which can each receive their own work_mem budget.
- Raising work_mem to fix hash spills without accounting for hash_mem_multiplier.
- Assuming temporary-table buffers are controlled here; those are governed by temp_buffers.
Related parameters
hash_mem_multiplier · temp_file_limit · log_temp_files · max_connections · max_parallel_workers_per_gather