pg_basebackup
can also be used to take base backups of a running PostgreSQL database cluster, but we are using WAL-G.wal-g
access to external storage.archive_command = 'wal-g wal-push% p'
wal-g backup-push $PGDATA
wal-g
delete
retain FULL 30
wal-g
backup-pull
$PGDATA
wal-g wal-fetch
restore command WALG_DELTA_MAX_STEPS
. pg_dump
. pg_dump
is used to create a logical dump of one or several DBs in cluster. pg_dump
is a utility for backing up a PostgreSQL database.pg_dump
only dumps a single database. To back up an entire cluster, or to back up global objects that are common to all databases in a cluster, use pg_dumpall
pg_dump
was called.pg_dump
works best for small databases (< 5 GB) and assumes downtime.