Introducing Pacemaker from CentOS 7 repository to RHEL7

1 minute read

Introducing Pacemaker from CentOS 7 repository to RHEL7


OS: Red Hat Enterprise Linux Server VERSION 7.8 (Maipo)
Additional repo: CentOS7

Installation procedure

If you don’t have a HA Add-on subscription, Pacemaker can add a CentOS Base repository and install from there. (No Red Hat support)

The procedure is described below, but please note that there is some missing information.

ClusterLabs RHEL 7 Quickstart

add repo

# cat <<'EOF' > /etc/yum.repos.d/centos.repo
name=CentOS-$releasever - Base

–Added gpgkey specification
–You may set gpgcheck = 0 without describing gpgkey =.
–It is also possible to add gpgkey by the following command without describing gpgkey =.

# rpm --import

–When enabled = 0, it is disabled so as not to conflict with other repositories.
–can also be specified by yum-config-manager –disable centos-7-base
-Valid with yum repolist(|Invalid|all)You can check the repository that is


# yum \
--disablerepo='*' \
--enablerepo=centos-7-base \
--releasever=7 \
install -y pacemaker pcs resource-agents

–Temporarily disable the repository you normally use, enable centos-7-base and try to install it.
—- Specify release ver = 7 (or set $ release to 7 in /etc/yum.repos.d/centos.repo)
–Note: Problem with 7Server where $ release was deployed in RHEL7. Considering simultaneous use with other RHEL repo, it seems better to edit /etc/yum.repos.d/centos.repo directly.

Installation of crmsh (optional)

To use the crm command recommended by Linux-HA etc., it is necessary to install from another repository.


crmsh repo added

# yum-config-manager --add-repo

# yum-config-manager --disable network_ha-clustering_Stable

-(Although it is not in the original procedure) This is also disabled.

Example of introducing pacemaker and crmsh at the same time

# yum \
--disablerepo='*' \
--enablerepo=centos-7-base,network_ha-clustering_Stable \
--releasever=7 \
install -y pacemaker pcs resource-agents crmsh

Ansible Playbook (task) example

- yum_repository:
    name: centos-7-base
    description: CentOS-7 - Base

- shell: |-
    set -x
    exec 2>&1
    yum-config-manager --add-repo
  register: r

- debug:
    var: r.stdout_lines

- yum:
    - pcs
    - pacemaker
    - corosync
    - resource-agents
    - corosync-qdevice
    - corosync-qnetd
    - crmsh
    #releasever: 7
    #disablerepo: '*'
      #- centos-base
      #- network_ha-clustering_Stable