41.5. Managing Nodes #

Before performing instructions from this section, create a cluster.

41.5.1. Viewing Nodes #

  1. In the navigation panel, go to InfrastructureClusters.

  2. Click the name of the cluster.

The table of nodes with the following columns will be displayed:

  • Instance: The unique name of the instance.

    This column includes additional information:

    Type: The type of the node.

    Possible values:

    • Primary/Leader.

    • Standby/Follower.

    • Cascade.

    • Referee.

  • Parent node: The primary/leader node of the cluster.

  • Status / Current operation: The status of the instance.

    Possible values:

    • Unknown: The status of the instance is unknown.

    • Initialization scheduled: The instance initialization was scheduled.

    • Initializing: The instance is being initialized.

    • Initialized: The instance is initialized.

    • Restoring: The instance is being created from a backup.

    • Restored: The instance is created from a backup.

    • Restore canceled: The creation of an instance from a backup was canceled.

    • Starting: The instance is being started.

    • Available: The instance is available.

    • Stopping: The instance is being stopped.

    • Stopped: The instance is stopped.

    • Restarting: The instance is being restarted.

    • Reloading: The cluster is being reloaded.

    • Replica initialization: The standby is being initialized.

    • Error: There is an error with the instance. For detailed information about the error, click the status.

    • Deleting: The instance is being deleted.

    • Agent not responding: The agent installed on the instance server is not responding.

    • Upgrading: The instance is being upgraded.

    • Upgraded: The instance is upgraded.

    • Agent not responding: The agent installed on the instance server is not responding.

  • Replication mode.

    Possible values:

    • Synchronous.

    • Asynchronous.

    This column includes additional information:

    Status: The status of replication.

    Possible values:

    • Active.

    • Inactive.

  • Network address: The network address of the node.

    This column includes additional information:

    Server: The server where the instance is installed.

  • User: The role used for connecting the standby/follower node to the primary/leader node.

  • Application: The application used for connecting the standby/follower node to the primary/leader node.

  • Connection: The date and time when the standby/follower node connected to the primary/leader node.

  • Horizon visibility: The transaction visibility horizon of the node.

  • Lag: The data lag between the primary/leader and the standby/follower node, in bytes.

    This column includes additional information:

    • Send: The amount of WAL generated by the primary/leader node, but not yet sent to the standby/follower node.

    • Write: The amount of WAL sent to the standby/follower node, but not yet written to the memory.

    • Flush: The amount of WAL written to the memory of the standby/follower node, but not yet saved to the disk.

    • Replay: The amount of WAL saved to the disk of the standby/follower node, but not yet applied to the database.

  • Lag time: The time lag between the primary/leader and the standby/follower node, in seconds.

    This column includes additional information:

    • Write: The time passed between the primary/leader node sending WAL to the standby/follower node and the standby/follower node writing it to the memory.

    • Flush: The time passed between the standby/follower node writing WAL to the memory and saving it to the disk.

    • Replay: The time passed between the standby/follower node saving WAL to the disk and applying it to the database.

  • Reply time: The date and time when the primary/leader node last received information from the standby/follower node.

  • Actions.

    For more information about available actions, refer to the corresponding instructions.

41.5.2. Selecting a New Primary/Leader Node #

  1. In the navigation panel, go to InfrastructureClusters.

  2. Click the name of the cluster.

  3. Click next to the standby/follower node.

  4. For a standard primary-standby cluster, select the mode:

    • Switchover: Planned node promotion when the primary node is running normally. The primary node is stopped and, when the switchover process is finished, it is re-started as a standby node.

    • Failover: Emergency node promotion due to the primary node failure. In this mode, the primary availability is checked to avoid the split-brain issue. The former primary node is not automatically re-started as a standby node and remains unchanged.

  5. Confirm the operation and click Confirm.

41.5.3. Adding a Standby/Follower Node #

  1. In the navigation panel, go to InfrastructureClusters.

  2. Click the name of the cluster.

  3. In the top-right corner of the page, click Edit topology.

  4. Click Add server.

  5. From Server, select a server to install the instance.

    When the server is selected, the following instance information is displayed:

    • Data directory: The path to the server directory where the main instance directories and files are located.

    • Network address and Port: The network address and port that the instance uses to accept client connections.

  6. Click Save.

41.5.4. Adding a Referee Node #

  1. In the navigation panel, go to InfrastructureClusters.

  2. Click the name of the BiHA cluster.

  3. In the top-right corner of the page, click Edit topology.

  4. From Referee, select a server to install the instance.

    When the server is selected, the following instance information is displayed:

    • Data directory: The path to the server directory where the main instance directories and files are located.

    • Network address and Port: The network address and port that the instance uses to accept client connections.

  5. From Referee operating mode, select one of the following values:

    • referee

    • referee_with_wal

    For more information, refer to the official Postgres Pro documentation on the referee node in the BiHA cluster.

  6. Click Save.

41.5.5. Replacing a Referee Node #

You can replace the server to host the referee node in your BiHA cluster. The new referee is installed on the new server, while the current referee instance is removed from the cluster, and you can decide how to handle the removed instance.

  1. In the navigation panel, go to InfrastructureClusters.

  2. Click the name of the BiHA cluster.

  3. In the top-right corner of the page, click Edit topology.

  4. From Referee, select the new server to install the instance.

    When the server is selected, the following instance information is displayed:

    • Data directory: The path to the server directory where the main instance directories and files are located.

    • Network address and Port: The network address and port that the instance uses to accept client connections.

  5. From Referee operating mode, select one of the following values:

    • referee

    • referee_with_wal

    For more information, refer to the official Postgres Pro documentation on the referee node in the BiHA cluster.

  6. From Current referee, select the actions you want to perform with the current referee instance:

    • Restart as standalone instance

    • Update configuration and remove node from cluster

    • Delete with all data

  7. Click Save.

41.5.6. Deleting a Node #

Important

  • You can only delete standby/follower or referee nodes.

    To delete the primary/leader node, select a new primary/leader node first.

  • Deleted nodes cannot be restored.

  1. In the navigation panel, go to InfrastructureClusters.

  2. Click the name of the cluster.

  3. Click next to the node.

  4. After deleting the node, associated tasks will be deactivated, and its backups will remain in the storage. Click Go to tasks to assign tasks to another node or Go to backups to bind another node to the backup storage.

  5. Select one of the following options:

    • Update configuration and remove node from cluster: The node will be removed from the cluster and restarted as a standalone instance.

    • Stop and remove from cluster: The node will be stopped, its data catalog will be preserved.

    • Delete only from PPEM: Only the node record will be deleted from the PPEM database. The node itself will remain.

    • Delete with all data: The node will be stopped and data catalog will be deleted.

  6. Confirm the operation and click Delete.

You can also delete standby/follower nodes in one of the following ways:

  • When editing the topology of the cluster. To do this, in the top-right corner of the page, click Edit topology.

  • From the table of instances. To do this, in the navigation panel, go to InfrastructureInstances.