This is an archive version of the document. To get the most up-to-date information, see the current version.

Preparing Password File for PostgreSQL Processing

You can use PostgreSQL account credentials that are stored in the password file to connect Veeam Agent to the PostgreSQL database system.

If you want to use a password file for authentication, create the .pgpass file in the home directory of the root user.

The password file must have the following contents:

<hostname>:<port>:<database>:<username>:<password>

where:

  • <hostname> — name of the host where the PostgreSQL database system is located.
  • <port> — number of the free port that Veeam Agent will use to connect to the PostgreSQL database system.
  • <database> — name of the PostgreSQL database.
  • <username> — name of the account that Veeam Agent will use to connect to the PostgreSQL database system.
  • <password> — password of the account that Veeam Agent will use to connect to the PostgreSQL database system.

For example:

srv01:5432:mydb:postgres:P@ssw0rd

For more information about the password file, see PostgreSQL documentation.

The PostgreSQL database system can use connection settings from one of the following files:

  • postgresql.conf
  • .pgpass

By default, Veeam Agent applies connection settings from the postgresql.conf file. If you specify host name and port number in the .pgpass file, Veeam Agent will use host name and port number from the .pgpass file instead of the postgresql.conf file to connect to the PostgreSQL database system. If you replace the value in the .pgpass file with the asterisk (*) sign, Veeam Agent uses the value from the postgresql.conf file.

For example:

*:*:mydb:postgres:P@ssw0rd