File tree Expand file tree Collapse file tree 1 file changed +37
-0
lines changed Expand file tree Collapse file tree 1 file changed +37
-0
lines changed Original file line number Diff line number Diff line change 1+ # pg_basebackup
2+
3+ > Take a base backup of a running PostgreSQL cluster.
4+ > Used for full or incremental backups, point-in-time recovery, or setting up replication standbys.
5+ > More information: < https://www.postgresql.org/docs/current/app-pgbasebackup.html > .
6+
7+ - Take a base backup from a remote PostgreSQL server:
8+
9+ ` pg_basebackup {{[-h|--host]}} {{host}} {{[-D|--pgdata]}} {{path/to/backup_dir}} `
10+
11+ - Take a backup with progress shown:
12+
13+ ` pg_basebackup {{[-h|--host]}} {{host}} {{[-D|--pgdata]}} {{path/to/backup_dir}} {{[-P|--progress]}} `
14+
15+ - Create a compressed backup (` gzip ` ) in tar format:
16+
17+ ` pg_basebackup {{[-D|--pgdata]}} {{path/to/backup_dir}} {{[-F|--format]}} {{[t|tar]}} {{[-z|--gzip]}} `
18+
19+ - Create an incremental backup using a previous manifest file:
20+
21+ ` pg_basebackup {{[-D|--pgdata]}} {{path/to/backup_dir}} {{[-i|--incremental]}} {{path/to/old_manifest}} `
22+
23+ - Write a recovery configuration for setting up a standby:
24+
25+ ` pg_basebackup {{[-D|--pgdata]}} {{path/to/backup_dir}} {{[-R|--write-recovery-conf]}} `
26+
27+ - Relocate a tablespace during backup:
28+
29+ ` pg_basebackup {{[-D|--pgdata]}} {{path/to/backup_dir}} {{[-T|--tablespace-mapping]}} {{path/to/old_tablespace}}={{path/to/new_tablespace}} `
30+
31+ - Limit transfer rate to reduce server load:
32+
33+ ` pg_basebackup {{[-D|--pgdata]}} {{path/to/backup_dir}} {{[-r|--max-rate]}} {{100M}} `
34+
35+ - Stream WAL logs while taking the backup:
36+
37+ ` pg_basebackup {{[-D|--pgdata]}} {{path/to/backup_dir}} {{[-X|--wal-method]}} stream `
You can’t perform that action at this time.
0 commit comments