Skip to main content
Version 4.0.0

High Availability Agent Configuration via PgSmart Web

Here are the necessary commands to configure the high availability Agent in the PostgreSQL Ecosystem:

Prerequisites
note

In a high availability environment, it is recommended to use dedicated servers for each component.

  1. Select the desired Environment from the dropdown in the top bar.

  2. Select the Alta Disponibilidade option in the sidebar. If there are registered High Availability Services, the cards for the registered components (Patroni) for the selected Environment will be displayed.

  3. Select the Agente tab.

  4. Click Inicializar.

    Figure 1 - High Availability Agent Configuration - Select Option
    Figure 1 - High Availability Agent Configuration - Select Option
  5. Enter the Name of the server identification.

  6. Select the Connection Interface of the high availability Agent.

  7. Enter the Port of the high availability Agent connection.

  8. Click Avançar.

    Figure 2 - High Availability Agent Configuration - Agent Identification
    Figure 2 - High Availability Agent Configuration - Agent Identification
  9. Select the network interface for monitoring the PostgreSQL instance. (So that the agent knows where the PostgreSQL instance is located and can monitor it.).

  10. Select the network interface for PostgreSQL instance access.

  11. Confirm the existence of the PostgreSQL instance.

  12. Click Avançar.

    Figure 3 - High Availability Agent Configuration - Network Interface
    Figure 3 - High Availability Agent Configuration - Network Interface
  13. Enter the PostgreSQL instance connection Port.

  14. Select the Major Version of the PostgreSQL instance.

  15. Enter the PostgreSQL instance Data Directory.

  16. Enter the PostgreSQL Database transaction log directory (WALDIR).

  17. Enter the path to the PostgreSQL password file (PGPASS).

  18. Confirm the existence of a PostgreSQL MASTER instance in the high availability environment.

  19. Click Avançar.

    Figure 4 - High Availability Agent Configuration - Instance Identification
    Figure 4 - High Availability Agent Configuration - Instance Identification
  20. Enter the Replication User name.

  21. Enter the Replication User password.

  22. Enter the High Availability Agent user name.

  23. Enter the High Availability Agent user password.

  24. Click Avançar.

    Figure 5 - High Availability Agent Configuration - Replication User
    Figure 5 - High Availability Agent Configuration - Replication User
  25. Confirm if the PostgreSQL instance can be promoted to Master in a Failover.

  26. Confirm if the instance can be cloned to automatically recreate others. (Requires database instance template).

  27. Confirm if the instance supports synchronous replication.

  28. Click Avançar.

    Figure 6 - High Availability Agent Configuration - Instance Details
    Figure 6 - High Availability Agent Configuration - Instance Details
  29. Select the default character encoding (ENCODING).

  30. Select the default locale for date and currency representations (LOCALE).

  31. Confirm if checksum for data pages should be enabled.

  32. Select the network interface used for data replication.

  33. Click Avançar.

    Figure 7 - High Availability Agent Configuration - Character Encoding, Locale
    Figure 7 - High Availability Agent Configuration - Character Encoding, Locale

    If you wish to add users to the initialization template: 33.1. Enter the name of the initialization template user. 33.2. Enter the password of the initialization template user. 33.3. Specify user privileges. 33.4. Click Avançar.

    Figure 8 - High Availability Agent Configuration - Initialization Template
    Figure 8 - High Availability Agent Configuration - Initialization Template

    If you wish, add access rules to the PostgreSQL instance: 33.5. Select the Access Type. 33.6. Enter the Host or IP/CIDR. 33.7. Select the authentication method. 33.8. Enter the Database(s). 33.9. Enter the User(s) or Groups. 33.10. Click Avançar.

    Figure 9 - High Availability Agent Configuration - Instance Access Rules
    Figure 9 - High Availability Agent Configuration - Instance Access Rules
  34. Select the proxy servers that will connect to this instance.

  35. Click Avançar.

    Figure 10 - High Availability Agent Configuration - Proxy Servers
    Figure 10 - High Availability Agent Configuration - Proxy Servers
  36. Review the summary screen and click Concluir to initialize the high availability agent.

    Figure 11 - High Availability Agent Configuration - Confirmation
    Figure 11 - High Availability Agent Configuration - Confirmation
    note
    • To confirm the default values provided, simply fill in the additional fields and proceed to the next screens.

    • If you do not wish to initialize the cluster member, leave all fields blank.