Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
J
joohanhong
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
JooHan Hong
joohanhong
Commits
6bea6ebd
Commit
6bea6ebd
authored
Feb 20, 2023
by
JooHan Hong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
zabbix-ha contents input4
parent
216e12f0
Pipeline
#6970
passed with stages
in 1 minute and 3 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
81 additions
and
0 deletions
+81
-0
README.md
MON/ZABBIX/README.md
+81
-0
No files found.
MON/ZABBIX/README.md
View file @
6bea6ebd
...
...
@@ -178,4 +178,85 @@ DBPassword=ghdwngkselql
Pacemaker는 Heartbeat Network으로 구성되기 때문에 다음과 같이
`/etc/hosts`
파일에 IP를 설정한다.
```
bash
# cat /etc/hosts
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
172.16.0.211 zabbix211
172.16.0.217 zabbix217
```
1.
패키지 설치 및 기본구성
```
bash
# yum install pcs fence-agents-all
# systemctl start pcsd; systemctl enable pcsd
# echo 패스워드 | passwd --stdin hacluster
# pcs cluster auth zabbix211 zabbix217
# pcs cluster setup --start --name ZABBIX zabbix211 zabbix217
# pcs cluster enable --all
# pcs property set stonith-enabled=false
# pcs property set no-quorum-policy=ignore
```
2.
VIP 클러스터 리소소 구성
```
bash
# pcs resource create PU-VIP IPaddr2 ip=61.100.0.244 cidr_netmask=32 nic=eth0 op monitor interval=10s timeout=30s on-fail=standby
# pcs resource create PR-VIP IPaddr2 ip=172.16.0.244 cidr_netmask=32 nic=eth1 op monitor interval=10s timeout=30s on-fail=standby
```
3.
Zabbix Server 요소별 리소스 구성
```
bash
# pcs resource create HTTPD systemd:httpd
# pcs resource create PHP-FPM systemd:rh-php72-php-fpm
# pcs resource create GRAFANA systemd:grafana-server
# pcs resource create ZABBIX systemd:zabbix-server
```
> GRAFANA는 Zabbix의 그래프 인터페이스를 개선하기 위한 연동이다. Grafana는 아주 훌륭한 그래프를 제공해 준다.
4.
클러스터 리소스의 순서 제약조건을 구성
```
bash
# pcs constraint order start PU-VIP then start PR-VIP
# pcs constraint order start PR-VIP then start PHP-FPM
# pcs constraint order start PHP-FPM then start HTTPD
# pcs constraint order start HTTPD then start GRAFANA
# pcs constraint order start GRAFANA then start ZABBIX
```
5.
요소별 리소스가 위치하는 제약조건을 구성
```
bash
# pcs constraint colocation add PU-VIP with PR-VIP
# pcs constraint colocation add PR-VIP with PHP-FPM
# pcs constraint colocation add PHP-FPM with HTTPD
# pcs constraint colocation add HTTPD with GRAFANA
# pcs constraint colocation add GRAFANA with ZABBIX
# pcs constraint location ZABBIX prefers zabbix211=100
```
!참고 : 다음은 Zabbix Proxy의 Pacemaker 구성내역이다.
```
bash
# pcs resource create PU-VIP IPaddr2 ip=61.100.0.220 cidr_netmask=32 nic=eth0 op monitor interval=10s timeout=30s on-fail=standby
# pcs resource create PR-VIP IPaddr2 ip=172.16.0.220 cidr_netmask=32 nic=eth1 op monitor interval=10s timeout=30s on-fail=standby
# pcs resource create ZABBIX-PROXY systemd:zabbix-proxy
# pcs constraint order start PU-VIP then start PR-VIP
# pcs constraint order start PR-VIP then start ZABBIX-PROXY
# pcs constraint colocation add PU-VIP with PR-VIP
# pcs constraint colocation add PR-VIP with ZABBIX-PROXY
# pcs constraint location ZABBIX-PROXY prefers zabbix-proxy224=100
```
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment