Scheduling PostgreSQL backups from NetBackup for Windows.

Article: 100044130
Last Published: 2018-10-04
Ratings: 1 0
Product(s): NetBackup

Description

You can initiate PostgreSQL backups in NetBackup using the DataStore policy to call a backup script.

 

Solution:

This article provides an sample script to schedule an automatic backup using the NetBackup Administration Console. You must copy the script to a preferred location, but ensure that the path is a white listed path. Use this script when configuring the DataStore policy for backups.

Note: You must modify the sample script according to your environment.

 

Steps 

To backup PostgreSQL database using the backup script

  1. Authenticate the password in the PostgreSQL environment.
  2. Download the sample script and copy it to a preferred chosen location.
  3. Rename the script postgresql_test_bat if required to a desirable name.
  4. Create a password file and in the body of the file enter the following

    PASSWORD=P@ssword!

  5. Modify the path according to the environment.
  6. In NetBackup Administration Console, create an automatic full backup schedule in the Policy>Schedule>Attributes tab.
  7. Under the Backup Selections tab, provide the path to the modified script as the backup selection.
  8. Under the Client tab, specify the PostgreSQL server.
  9. Specify the parameters for the backup operation in the nbpgsql.conf file.
  10. Run the backup using the NetBackup Administration Console.

 

Notes:

The password file that is created can be in any location on the postgres client, the full path of the password file needs to be used in the text file that is created.

 

Was this content helpful?