Skip to main content

pgbench

Database

PostgreSQL heavy read-only throughput​

Measures PostgreSQLPostgreSQLAn open-source object-relational database system, developed by a global community and descended from the POSTGRES project at UC Berkeley in 1986. It uses and extends SQL, with transactions, many index types, extensions, and JSON data.PostgreSQL docsGlossary throughput with a remote pgbench client against a custom, cache-resident, read-only transaction (joins, aggregates, full-text search, arrays, regex, TOAST) that fits in shared_buffers, so the score reflects engine CPUCPU: Central Processing UnitThe general-purpose processor of a computer, which runs the operating system and programs. A CPU has one or more physical cores, and with SMT each core runs two or more hardware threads.WikipediaGlossary and memory behavior rather than disk or network. Server and client run in the same availability zone. Servers use pgtune-style host GUCs, while DBaaS keep the vendor-managed config. Each score is TPM at a given client concurrency; the typical profile is 1, vCPUs/2, vCPUsvCPU: virtual CPUA CPU of a virtual machine, the unit in which cloud vendors sell compute. It is usually one hardware thread of a physical core with SMT, so two vCPUs may share one physical core.WikipediaGlossary, and 2*vCPUs (additional points may be present). This is a synthetic proxy for relative RDBMS performance across server types, not a prediction of any specific application's throughput.

Benchmark details

Benchmark ID
pgbench:heavy_read_only
Unit of measurement
Transactions per minute (TPM)
Server types evaluated
825
Total measurements
3,150
Range of measurements
32 – 37.1K TPM
Better
↑ Higher is better

Configuration options

FieldDescriptionExample values
concurrencyParallel client query count (integer). Typical profile: 1, vCPUs/2, vCPUs, and 2*vCPUs (may include additional points).1 2 3 4 6 7 8 10 11 12 14 15 16 18 19 20 22 24 28 30 32 36 38 40 44 45 48 52 56 60 64 72 76 80 88 90 96 104 112 120 128 144 160 176 180 192 208 224 256 288 320 360 384 448 576 720 768

Score distribution (3,150 measurements)

Score distribution of PostgreSQL heavy read-only throughput

PostgreSQL heavy read-only peak throughput​

Maximum PostgreSQL throughput over the pgbench concurrency profile (typically 1, vCPUs/2, vCPUs, and 2*vCPUs) with a remote client against a custom, cache-resident, read-only transaction (joins, aggregates, full-text search, arrays, regex, TOAST) that fits in shared_buffers. Server and client run in the same availability zone. Servers use pgtune-style host GUCs, while DBaaS keep the vendor-managed config. This is a synthetic proxy for relative RDBMS performance across server types, not a prediction of any specific application's throughput.

Benchmark details

Benchmark ID
pgbench:heavy_read_only:peak
Unit of measurement
Transactions per minute (TPM)
Server types evaluated
825
Total measurements
825
Range of measurements
45 – 37.1K TPM
Better
↑ Higher is better

Score distribution (825 measurements)

Score distribution of PostgreSQL heavy read-only peak throughput

PostgreSQL heavy read-only baseline (single connection)​

Baseline PostgreSQL throughput with a single remote pgbench client connection against a custom, cache-resident, read-only transaction (joins, aggregates, full-text search, arrays, regex, TOAST) that fits in shared_buffers. Server and client run in the same availability zone. Servers use pgtune-style host GUCs, while DBaaS keep the vendor-managed config. Useful for comparing per-session engine and CPU efficiency across server types and sizes, because the score does not necessarily scale with extra vCPUs the way peak throughput does. This is a synthetic proxy for relative RDBMS performance, not a prediction of any specific application's throughput.

Benchmark details

Benchmark ID
pgbench:heavy_read_only:single
Unit of measurement
Transactions per minute (TPM)
Server types evaluated
825
Total measurements
825
Range of measurements
38 – 299 TPM
Better
↑ Higher is better
warning

This benchmark is measured with a single client session, so throughput does not necessarily grow with vCPU count. On the other hand, it is not a purely single-threaded metric, as the server may still engage multiple cores (e.g. parallel request handlers and background processes). Use it as a per-session efficiency baseline rather than a measure of instance capacity.

Score distribution (825 measurements)

Score distribution of PostgreSQL heavy read-only baseline (single connection)