Configure a remote node

Configure a Pacemaker Remote node and integrate it into the existing cluster.

Procedure

  1. On the node that you will be configuring as a remote node, allow cluster-related services through the local firewall.
    # firewall-cmd --permanent --add-service=high-availability
    success
    # firewall-cmd --reload
    success
    Note

    If you are using iptables directly, or some other firewall solution besides firewalld, open the following ports: TCP ports 2224 and 3121.

  2. Install the pacemaker_remote daemon on the remote node.
    # dnf install -y pacemaker-remote resource-agents pcs
  3. Start and enable pcsd on the remote node.
    # systemctl start pcsd.service
    # systemctl enable pcsd.service
  4. If you have not already done so, authenticate pcs to the node you will be adding as a remote node.
    # pcs host auth remote1
  5. Add the remote node resource to the cluster with the following command. This command also syncs all relevant configuration files to the new node, starts the node, and configures it to start pacemaker_remote on boot. This command must be run on a cluster node and not on the remote node which is being added.
    # pcs cluster node add-remote remote1
  6. After adding the remote resource to the cluster, you can treat the remote node just as you would treat any other node in the cluster. For example, you can create a resource and place a resource constraint on the resource to run on the remote node as in the following commands, which are run from a cluster node.
    # pcs resource create webserver apache configfile=/etc/httpd/conf/httpd.conf op monitor interval=30s
    # pcs constraint location webserver prefers remote1
    Warning

    Never involve a remote node connection resource in a resource group, colocation constraint, or order constraint.

  7. Configure fencing resources for the remote node. Remote nodes are fenced the same way as cluster nodes. Configure fencing resources for use with remote nodes the same as you would with cluster nodes. Note, however, that remote nodes can never initiate a fencing action. Only cluster nodes are capable of actually running a fencing operation against another node.