You are on page 1of 2

CÔNG TY TNHH HỆ THỐNG THÔNG TIN FPT

XÂY DỰNG PHẦN MỀM SỐ HÓA CÁC QUY TRÌNH NGHIỆP VỤ

KỸ THUẬT – AN TOÀN, KINH DOANH – DỊCH VỤ KHÁCH HÀNG,

TÀI CHÍNH KẾ TOÁN

TÀI LIỆU HƯỚNG DẪN CÀI ĐẶT HA CLUSTER

Số hợp đồng

Mã dự án EVNNPC_SH1_2021_PM

Mã tài liệu IM

Phiên bản tài liệu 1.0

Quy trình cài đặt HA Cluster


- Chỉnh sửa file /etc/hosts.
10.21.51.129 spro-500plus-app01
10.21.51.130 spro-500plus-app02
- Cài đặt các gói hỗ trợ RHEL HA và fencing

# yum install -y pacemaker pcs psmisc policycoreutils-python fence-agents-vmware-soap

- Disabled the firewall & selinux

# vi /etc/selinux/config

SELINUX=disabled

# systemctl stop firewalld.service

# systemctl disable firewalld.service

- Thực hiện start dịch vụ của cluster trên cả 2 node

# systemctl start pcsd.service

Lưu hành nội bộ VETC/FIS Trang 1


# systemctl enable pcsd.service

- Đặt password cho user hacluster trên các node

- # passwd hacluster

- Thực hiện authenticate user hacluster giữa các node:

# pcs cluster auth spro-500plus-app01 spro-500plus-app02

Username: hacluster

Password:

rhel73-02: Authorized

rhel73-01: Authorized

- Thực hiện tạo cluster và start

# pcs cluster setup --name ha_cluster spro-500plus-app01 spro-500plus-app02

# pcs cluster start --all


- Cài đặt tự động bật cluster khi boot máy bằng lệnh:

# systemctl enable corosync.service

# systemctl enable pacemaker.service


- Thực hiện cấu hình fencing bằng vmware soad cho hệ thống

# pcs property set stonith-enabled=true

# pcs property set stonith-action=reboot

# pcs property set stonith-timeout=120s

#pcs stonith create vmfence fence_vmware_rest pcmk_host_map="spro-500plus-


app01:10.21.51.129-CDS-Spro-500Plus-APP;spro-500plus-app02:10.21.51.130-CDS-Spro-
500Plus-APP-Backup" ipaddr=10.21.46.70 ssl=1 login=<vcenter_user>
passwd=<vcenter_password> ssl_insecure=1

Kiểm tra cấu hình


# pcs stonith show

# pcs stonith show vmfence

# pcs status

You might also like