Search PostgreSQL documentation
PG 18 · Browse by category, or enter a name or keyword
Category index35
baseSubdirectory containing per-database subdirectories
PGDATA paths
$PGDATA/base
Relative path base
current_logfilesFile recording the log file(s) currently written to by the logging collector
PGDATA paths
$PGDATA/current_logfiles
Relative path current_logfiles
Database File LayoutThis section describes the storage format at the level of files and directories.
Physical structures
Definition scope Same-version core physical storage documentation
Contents of PGDATA
PG_…
Database Page LayoutThis section provides an overview of the page format used within PostgreSQL tables and indexes. [20] Sequences and TOAST tables are formatted just like a regular table.
Physical structures
…
Free Space MapEach heap and index relation, except for hash indexes, has a Free Space Map ( FSM ) to keep track of available space in the relation. It's stored alongside the main relation data in a separa…
fsm forkEach table and index is stored in a separate file. For ordinary relations, these files are named after the table or index's filenode number, which can be found in pg_class . relfilenode . Bu…
globalSubdirectory containing cluster-wide tables, such as pg_database
PGDATA paths
$PGDATA/global
Relative path global
Heap-Only Tuples ( HOT )To allow for high concurrency, PostgreSQL uses multiversion concurrency control ( MVCC ) to store rows. However, MVCC has some downsides for update queries. Specifically, updates require new…
init forkEach table and index is stored in a separate file. For ordinary relations, these files are named after the table or index's filenode number, which can be found in pg_class . relfilenode . Bu…
main forkEach table and index is stored in a separate file. For ordinary relations, these files are named after the table or index's filenode number, which can be found in pg_class . relfilenode . Bu…
pg_commit_tsSubdirectory containing transaction commit timestamp data
PGDATA paths
$PGDATA/pg_commit_ts
Relative path pg_commit_ts
pg_dynshmemSubdirectory containing files used by the dynamic shared memory subsystem
PGDATA paths
$PGDATA/pg_dynshmem
Relative path pg_dynshmem
pg_logicalSubdirectory containing status data for logical decoding
PGDATA paths
$PGDATA/pg_logical
Relative path pg_logical
pg_multixactSubdirectory containing multitransaction status data (used for shared row locks)
PGDATA paths
$PGDATA/pg_multixact
Relative path pg_multixact
pg_notifySubdirectory containing LISTEN/NOTIFY status data
PGDATA paths
$PGDATA/pg_notify
Relative path pg_notify
pg_replslotSubdirectory containing replication slot data
PGDATA paths
$PGDATA/pg_replslot
Relative path pg_replslot
pg_serialSubdirectory containing information about committed serializable transactions
PGDATA paths
$PGDATA/pg_serial
Relative path pg_serial
pg_snapshotsSubdirectory containing exported snapshots
PGDATA paths
$PGDATA/pg_snapshots
Relative path pg_snapshots
pg_statSubdirectory containing permanent files for the statistics subsystem
PGDATA paths
$PGDATA/pg_stat
Relative path pg_stat
pg_stat_tmpSubdirectory containing temporary files for the statistics subsystem
PGDATA paths
$PGDATA/pg_stat_tmp
Relative path pg_stat_tmp
pg_subtransSubdirectory containing subtransaction status data
PGDATA paths
$PGDATA/pg_subtrans
Relative path pg_subtrans
pg_tblspcSubdirectory containing symbolic links to tablespaces
PGDATA paths
$PGDATA/pg_tblspc
Relative path pg_tblspc
pg_twophaseSubdirectory containing state files for prepared transactions
PGDATA paths
$PGDATA/pg_twophase
Relative path pg_twophase
PG_VERSIONA file containing the major version number of PostgreSQL
PGDATA paths
$PGDATA/PG_VERSION
Relative path PG_VERSION
pg_walSubdirectory containing WAL (Write Ahead Log) files
PGDATA paths
$PGDATA/pg_wal
Relative path pg_wal
pg_xactSubdirectory containing transaction commit status data
PGDATA paths
$PGDATA/pg_xact
Relative path pg_xact
postgresql.auto.confA file used for storing configuration parameters that are set by ALTER SYSTEM
PGDATA paths
$PGDATA/postgresql.auto.conf
Relative path postgresql.auto.conf
postmaster.optsA file recording the command-line options the server was last started with
PGDATA paths
$PGDATA/postmaster.opts
Relative path postmaster.opts
postmaster.pidA lock file recording the current postmaster process ID (PID), cluster data directory path, postmaster start timestamp, port number, Unix-domain socket directory path (could be empty), first…
Table row layoutPhysical row headers, null bitmap, alignment and column data.
Physical structures
HeapTupleHeaderData Layout
t_xmin TransactionId 4 bytes insert XID stamp
t_xmax TransactionId 4 bytes delet…
The Initialization ForkEach unlogged table, and each index on an unlogged table, has an initialization fork. The initialization fork is an empty table or index of the appropriate type. When an unlogged table must …
TOASTThis section provides an overview of TOAST (The Oversized-Attribute Storage Technique).
Physical structures
Definition scope Same-version core physical storage documentation
Visibility MapEach heap relation has a Visibility Map (VM) to keep track of which pages contain only tuples that are known to be visible to all active transactions; it also keeps track of which pages cont…
vm forkEach table and index is stored in a separate file. For ordinary relations, these files are named after the table or index's filenode number, which can be found in pg_class . relfilenode . Bu…
WAL InternalsWAL is automatically enabled; no action is required from the administrator except ensuring that the disk-space requirements for the WAL files are met, and that any necessary tuning is done (…
More results
Find definitions in the PostgreSQL manuals, reference library, and extension catalogue.
Searching every version by default. Manual pages are indexed for PostgreSQL 10–20; the reference library and extension catalogue are not version-bound.
all: every version pg17: one version ex: extensions only ↑↓ select ↵ open