자동 가상 IP 복구 배치
Corosync 및 Pacemaker는 Private Cloud Appliance와 통합하고 보조 IP의 페일오버를 테스트하기 전에 클러스터에 설치해야 합니다.
클러스터 리소스 설정
클러스터 리소스를 설정하려면 다음을 실행합니다.
pcs resource create <Cluster-Resource-Name> ocf:heartbeat:IPaddr2 ip=10.212.15.13 cidr_netmask=24 op monitor interval=20
참고:
- Pacemaker 명령의
cidr_netmask=24
은 서브넷 크기 /24에 따라 달라집니다. IP=10.212.15.13
는 보조 전용 IP입니다.
예:
pcs status
Cluster name: HACluster
Stack: corosync
Current DC: a-node2 (version 1.1.23-1.0.1.el7_9.1-9acf116022) - partition with quorum
Last updated: Fri Aug 19 03:34:51 2022
Last change: Fri Aug 19 03:34:44 2022 by root via cibadmin on a-node1
2 nodes configured
1 resource instance configured
Online: [ a-node1 a-node2 ]
Full list of resources:
HAFailover (ocf::heartbeat:IPaddr2): Started a-node1
Daemon Status:
corosync: active/disabled
pacemaker: active/disabled
pcsd: active/enabled