PostgreSQL Data Directory

Every PostgreSQL installation requires that a base data directory be specified. Usually this is done with the initdb command during installation. This directory contains a number of files. The following is a typical listing of the files present in the default PostgreSQL data directory. (Note: These files may change from version to version, but a close approximation of these will exist.)

File Description
$PGBASE/PG_VERSION The file containing the version number of the version of PostgreSQL that created this data directory.
$PGBASE/base/ The directory that contains user-defined databases and the default template1 database.
$PGBASE/base/template1 The default template that is used as a model for all other user-created ...

Get PostgreSQL Essential Reference now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.