# commit_timestamp_buffers

> commit_timestamp_buffers — Sets the size of the dedicated buffer pool used for the commit timestamp cache. Observed in PG17–19 Beta 3; its last measured boot default is 0 B (0 × 8kB) in PG19 Beta 3, with postmaster context. This is a beta-snapshot fact and can change before PostgreSQL 19 GA.
---

> [!NOTE]
> **Fact — official short description:** “Sets the size of the dedicated buffer pool used for the commit timestamp cache.”

## Identity {#identity}

| Field | Value | Meaning |
| --- | --- | --- |
| Type | `integer` | Upstream pg_settings type |
| Context | `postmaster` | Requires a server restart |
| Unit | `8kB` | Raw unit |
| Range | `0` – `131072` | Raw limits in the last observed version |
| Enum values | — | — for non-enum types |
| Category | Resource Usage / Memory | Upstream classification |
| Latest boot value | `0` | 0 B (0 × 8kB) |
{.fields meta="-"}

## Lifecycle {#lifecycle}

| Fact | Value |
| --- | --- |
| First observed | PG17 |
| Present in | PG17–19 Beta 3 |
| Removed in | No |
| Introduction commit | [`53c2a97a9266`](https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=53c2a97a92665be6bd7d70bd62ae6158fe4db96e) — Improve performance of subsystems on top of SLRU |
| Commit date | 2024-02-28 |
| Discussion | [thread 1](https://postgr.es/m/2BEC2B3F-9B61-4C1D-9FB5-5FAB0F05EF86@yandex-team.ru) · [thread 2](https://postgr.es/m/CAFiTN-vzDvNz=ExGXz6gdyjtzGixKSqs0mKHMmaQ8sOSEFZ33A@mail.gmail.com) |

## Default history {#default-history}

| Versions | Raw `boot_val` | Unit | Human value |
| --- | --- | --- | --- |
| PG17–19 Beta 3 | `0` | `8kB` | 0 B (0 × 8kB) |
{.full-width caption="Measured PG9.0–19 Beta 3 boot defaults"}

## How it works {#mechanism}

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 {#tuning-advice}

> [!TIP]
> **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. |
{.full-width}

## Pigsty {#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 | — | — |
{.full-width}

> [!CAUTION]
> **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 {#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 {#related-parameters}

[`track_commit_timestamp`](/parameters/track-commit-timestamp/) · [`shared_buffers`](/parameters/shared-buffers/) · [`transaction_buffers`](/parameters/transaction-buffers/) · [`subtransaction_buffers`](/parameters/subtransaction-buffers/)

## References {#references}

- [PostgreSQL 19 Beta 3 — commit_timestamp_buffers](https://www.postgresql.org/docs/19/runtime-config-resource.html#GUC-COMMIT-TIMESTAMP-BUFFERS)
- [PostgreSQL 19 release notes](https://www.postgresql.org/docs/19/release-19.html)
- [Machine-readable GUC export](/data/guc.jsonl)
