Perform an Online PostgreSQL Backup
Caution: If you have configured high availability, do not perform an online backup at the standby node. For more information about high availability configurations, see High Availability.
You can use the online-pg-backup utility to perform an online backup of the PostgreSQL that contains Log Correlation Engine events and part of the Log Correlation Engine control state. Online backups can be created while Log Correlation Engine and PostgreSQL are running.
The control state online-pg-backup saves does not include all control files, such as policies or plugins. To save all control files, use the port-controlfiles utility.
Before you begin:
-
If this is the first time you are using the online-pg-backup utility, in the command line interface (CLI) in Log Correlation Engine, run the following command to restart PostgreSQL and all Log Correlation Engine daemons:
online-pg-backup --one-time-backup-prep
PostgreSQL and all Log Correlation Engine daemons restart.
To create an online PostgreSQL backup:
-
Log in to Log Correlation Engine via the command line interface (CLI).
-
In the CLI in Log Correlation Engine, run the following command:
online-pg-backup --backup-to <full path of directory>
PostgreSQL creates the backup files.
Note: This step may take 10-45 minutes to run, depending on the size of the backup file (10–20% of activeDb's size at the time backup was taken). Creating online backup files does not cause Log Correlation Engine or PostgreSQL downtime.
What to do next:
- (Optional) Restore the backup file, as described in Restore an Online PostgreSQL Backup.