zabbix monitoring mailbox alarm

Zabbix monitoring node mailbox alarm (follow the steps in the document to build success) The
document has done zabbix monitoring back-end server and sends emails by triggering an alarm.
Special note: This environment needs to deploy the zabbix server in advance, you can view my previous documents, the document link https://blog.csdn.net/zeorg/article/details/111937751
#####Be sure to follow the document when deploying You must carefully read every word (every word is important).
#私自转载Please contact the blogger, otherwise we must be investigated for copyright. There is WeChat under the copyright.
System environment: centos7

IP Node name
192.168.128.151 admin-zabbix
192.168.128.152 client

1. Modify the node name.
Client node execution

hostnamectl set-hostname client

2. Configure domestic yum source.
Client node execution

创建文件/etc/yum.repos.d/zabbix.repo
[zabbix]
name=Zabbix Official Repository - \$basearch
baseurl=https://mirrors.aliyun.com/zabbix/zabbix/4.0/rhel/7/\$basearch/
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-ZABBIX-A14FE591
 
[zabbix-non-supported]
name=Zabbix Official Repository non-supported - \$basearch
baseurl=https://mirrors.aliyun.com/zabbix/non-supported/rhel/7/\$basearch/
enabled=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-ZABBIX
gpgcheck=1
EOF
#######上面是需要写在yum里面的文件
curl https://mirrors.aliyun.com/zabbix/RPM-GPG-KEY-ZABBIX-A14FE591 \
-o /etc/pki/rpm-gpg/RPM-GPG-KEY-ZABBIX-A14FE591
 
curl https://mirrors.aliyun.com/zabbix/RPM-GPG-KEY-ZABBIX \
-o /etc/pki/rpm-gpg/RPM-GPG-KEY-ZABBIX

3. Install the client and configure files.
Client node execution

yum -y install zabbix-agent
配置文件etc/zabbix/zabbix_agentd.conf

98行  Server=192.168.182.151  ##zabbix服务器地址

139行 ServerActive=192.168.182.151 ##活跃服务器地址

150行 Hostname=client

4. The client zabbix-agent starts.
Client node execution

systemctl enable zabbix-agent
systemctl restart zabbix-agent

5. Configure the web terminal.
Configure Chinese interface
Insert picture description here
Insert picture description here

6. Configure the web terminal, add the host, add the monitoring host cpu and other information.

Insert picture description here

Insert picture description here

Insert picture description here


Insert picture description here
7. Configure the web terminal and add httpd monitoring.
Insert picture description here
8. Now check the dashboard on the web side and you can see that httpd has started to alarm because our client does not have httpd installed.
Insert picture description here
9. Install httpd on the
client and start the service client node execution

yum -y install httpd
systemctl start httpd
systemctl enable httpd

10. Go back to the web interface and you can see that the alarm has disappeared
Insert picture description here

11. Configure the mailbox smtp service (QQ mailbox as an example).
Insert picture description here
12. Configure the alarm media.
Insert picture description here
Insert picture description here
13. Configure alarm actions. (Add points after configuration, I didn’t mark it here)
Insert picture description here
Insert picture description here

14. Set up users and set whom to send to.
Insert picture description here
Insert picture description here
15. Close the httpd service of the client node.
Client node execution

systemctl stop httpd  

16. Look at the alarm on the web side (wait more).
Insert picture description here
17. Go to the QQ mailbox and you can see that there are emails sent in.
Insert picture description here

Guess you like

Origin blog.csdn.net/zeorg/article/details/112128191