Analysis of Linux Zabbix custom monitoring and alarm implementation process

Analysis of Linux Zabbix custom monitoring and alarm implementation process

Target

Display one of the data in the iostat command in the zabbix front-end monitoring.

iostat Command

The iostat command is used to monitor the usage of system input and output devices and CPU.

Here we take out the tps item of disk sda. Note: tps: Transactions Per Second, the number of transactions processed per second.

Add monitoring items on the monitored end

Create the file iotps.conf under /etc/zabbix/zabbix_agentd.d

The format of custom monitoring items is: UserParameter=<key>,<shell command>

Restart the service: systemctl restart zabbix-agent

examine:

Test whether the client-defined monitoring items are normal on the monitoring end

Install the check tool: yum -y install zabbix-get

Detection:

Note: Because Server=192.168.1.71 is used in the agent /etc/zabbix/zabbix_agentd.conf file, 192 IP must also be used here

Add custom monitoring items on the monitoring front-end page

Configuration---Host---Monitoring items in the web01 row---Create monitoring items in the upper right corner of the page---

Click Add --- Monitor --- Latest Data --- Found an additional sda tps

Custom alarm

Configuration---Host---Corresponding trigger under the host---Create trigger in the upper right corner of the page

Click Add, double-click the web01 label in xshell to open the new port, and the following alarm will appear under Monitoring---Problems:

At this time, close an xshell tab and wait for a while

Note: If you want it to update faster, you can set the update interval in the corresponding monitoring item (here is Number of logged in users). The system default is 1 minute.

Add sound alarm

Click user settings in the lower left corner---Sending messages---check the front-end information. Since we are unclassified here, give unclassified a sound and click Update.

Email alarm (taking 163 mailbox as an example)

Get the authorization code

Management---Alarm Media Type---Create Media Type in the upper right corner of the page

Click Update, find the alarm media type you created on the page that appears, and click Test (Success)

Click Add, Configure---Action---Create an action in the upper right corner of the page

Click Add, then click Actions

Click Add, click User Settings---Alarm Media---Add in the lower left corner of the page

Click Add, click Update, then we use xshell to log in to the two web01 servers, and the mailbox receives the email:

The above is the full content of this article. I hope it will be helpful for everyone’s study. I also hope that everyone will support 123WORDPRESS.COM.

You may also be interested in:
  • Detailed explanation of monitoring Jenkins process based on zabbix
  • Detailed explanation of the process of Zabbix active, passive and web monitoring in distributed monitoring system
  • Distributed monitoring system Zabbix uses SNMP and JMX channels to collect data
  • Detailed explanation of Zabbix monitoring SQL Server service status
  • How to monitor mysql using zabbix
  • How to use filters to implement monitoring in Zabbix
  • How does Zabbix monitor and obtain network device data through ssh?
  • Detailed tutorial for upgrading zabbix monitoring 4.4 to 5.0
  • Detailed steps for adding hosts you need to monitor in zabbix
  • Using zabbix to monitor the ogg process (Windows platform)

<<:  MySQL stored procedures and common function code analysis

>>:  JavaScript to achieve mouse tailing effect

Recommend

How to use docker to build redis master-slave

1. Build a Docker environment 1. Create a Dockerf...

Reasons why MySQL cancelled Query Cache

MySQL previously had a query cache, Query Cache. ...

A brief analysis of the use of watchEffect in Vue3

Preface Everyone should be familiar with the watc...

How to install redis in Docke

1. Search for redis image docker search redis 2. ...

Detailed explanation of the use of MySQL group links

Grouping and linking in MYSQL are the two most co...

25 Ways and Tips to Increase Web Page Loading Speed

Introduction <br />Not everyone has access t...

Summary of practical skills commonly used in Vue projects

Table of contents Preface 1. Use $attrs and $list...

Analysis of Sysbench's benchmarking process for MySQL

Preface 1. Benchmarking is a type of performance ...

How to implement form validation in Vue

1. Installation and use First, install it in your...

How can MySQL effectively prevent database deletion and running away?

Table of contents Safe Mode Settings test 1. Upda...

W3C Tutorial (16): Other W3C Activities

This section provides an overview of some other i...

Install two MySQL5.6.35 databases under win10

Record the installation of two MySQL5.6.35 databa...

Reflection and Proxy in Front-end JavaScript

Table of contents 1. What is reflection? 2. Refle...

Installation process of MySQL5.7.22 on Mac

1. Use the installation package to install MySQL ...