First time, we need an virtual machine with Ubuntu 18.04 for install Nginx Server and know the future IP address of servers zabbix.
- zabbix-sql01 – 10.0.0.4
- zabbix-node01 – 10.0.0.1
- zabbix-node02 – 10.0.0.2
- zabbix-node-vip – 10.0.0.3
- zabbix-web01 – 10.0.0.5
- zabbix-web02 – 10.0.0.6
- zabbix-web-vip – 10.0.0.7
Install Apache
# yum install -y httpd wget
# firewall-cmd --permanent --add-service=http
# firewall-cmd --reload
Create Website Documents
# vi /var/www/html/index.html
<html>
<body>My Test Site - 38</body>
</html>
# vi /etc/httpd/conf.d/status.conf
<Location /server-status>
SetHandler server-status
Require local
</Location>
# pcs resource create WebSite ocf:heartbeat:apache \
configfile=/etc/httpd/conf/httpd.conf \
statusurl="http://localhost/server-status" \
op monitor interval=1min
# pcs status
# wget -O - http://localhost/server-status
if any error
# vi /etc/httpd/conf/httpd.conf
PidFile /var/run/httpd.pid
stop all cluster and start it.
Comments
Post a Comment