DB Internals AtlasPostgreSQL 18.6 Home About

Parameters

Write-Ahead Log

40 PostgreSQL 18.6 parameters. Each one has its own animation and explanation.

Archive Recovery

  • archive_cleanup_command: Command run at each restartpoint on a standby, to prune archived WAL it no longer needs.
  • recovery_end_command: Shell command run once when archive recovery or standby mode ends.
  • restore_command: Shell command that fetches an archived WAL segment during recovery (%f, %p).

Archiving

  • archive_command: Shell command that copies a finished WAL segment to the archive (%p, %f).
  • archive_library: Archive WAL with a loadable module instead of a shell command (PostgreSQL 15+).
  • archive_mode: Turn on WAL archiving (on), or also archive on a standby (always).
  • archive_timeout: Force a WAL segment switch after this long, so quiet periods still get archived.

Checkpoints

  • checkpoint_completion_target: Fraction of the checkpoint interval used to spread the writes (default 0.9).
  • checkpoint_flush_after: Ask the OS to begin checkpoint writeback in smaller batches; the default is platform-dependent.
  • checkpoint_timeout: Longest time between automatic checkpoints (default 5 min).
  • checkpoint_warning: Log a warning if WAL-triggered checkpoints come closer together than this.
  • max_wal_size: Soft limit on pg_wal size; checkpoints are started early enough to stay below it.
  • min_wal_size: Keep at least this much WAL around for reuse, so bursts do not create new files.

Recovery

Recovery Target

Settings

  • commit_delay: Microseconds a committing session waits so others can share the same WAL flush.
  • commit_siblings: Minimum other active transactions before commit_delay is applied.
  • fsync: Never turn off in production: without fsync a crash can corrupt the whole cluster.
  • full_page_writes: Log a whole page image on first change after a checkpoint, to repair torn pages.
  • synchronous_commit: What COMMIT waits for: nothing, local disk, or standby write/flush/replay.
  • wal_buffers: Shared memory for WAL not yet written out. -1 = 1/32 of shared_buffers (max 16MB).
  • wal_compression: Compress full-page images in WAL with pglz, lz4 or zstd.
  • wal_init_zero: Fill new WAL segment files with zeroes before use (off can help on copy-on-write FS).
  • wal_level: How much information goes into WAL: crash-only, replicas, or logical decoding.
  • wal_log_hints: WAL-log pages changed only by hint bits; needed for pg_rewind without checksums.
  • wal_recycle: Reuse old WAL segment files by renaming them instead of deleting and recreating.
  • wal_skip_threshold: With wal_level=minimal, new relations smaller than this are WAL-logged, bigger are fsynced.
  • wal_sync_method: Which system call forces WAL to disk at commit (fdatasync on Linux by default).
  • wal_writer_delay: How often the WAL writer wakes to write and flush WAL in the background.
  • wal_writer_flush_after: How much WAL the WAL writer may write before it must also flush (fsync).

Summarization

  • summarize_wal: Run the WAL summarizer, needed for incremental backups (PostgreSQL 17+).
  • wal_summary_keep_time: How long WAL summary files are kept before automatic deletion (default 10 days).