Introduction to zabbix concepts and functions

         For operation and maintenance personnel, monitoring is very important, because if we want to ensure that the online business as a whole can operate stably, then we need to pay attention to whether the relevant indicators are normal in real time, and behind a business system, there are often With many hardware resources such as servers and network devices, if we want to be able to monitor them more conveniently and centrally, we need to rely on some external tools, and zabbix is ​​a widely used application that can realize centralized monitoring and management program.

                              

The original intention of our monitoring is that when certain indicators do not meet our needs, we can find anomalies in the first time. Therefore, monitoring tools need to regularly check and collect information on the monitored host. When the monitored host is abnormal At the time, we can report to the police and notify the administrator in time, and we need to record these abnormalities so that we can analyze the data and check the omissions. Then, a monitoring tool should have the functions of collecting information, storing information, displaying information, and alarm notification, and zabbix You can do this. In addition to zabbix, you may have heard of cacti, nagios, ganglia and other similar monitoring systems, but here, we only talk about zabbix. Zabbix 3.4 software manual

 

                                                    Zabbix from giving up to getting started (1): zabbix concept

 

Well, we probably understand zabbix, so what hardware resources can we monitor through zabbix? In theory, as long as it is hardware resources related to our business, it should be monitored, such as hosts, switches, routers, UPS, etc. Wait, but the premise of monitoring them is to be able to communicate with them, then the problem comes. Due to the different hardware, we cannot use a unified method to monitor them. At this time, the monitoring program needs to be universal, or Say, the monitoring program needs to be able to communicate with a variety of hardware devices to meet our monitoring needs. For example: if the monitored object is a server with the Linux operating system installed, then we can use ssh or telnet remotely. The tool establishes a communication channel with the monitored object, but if the monitored object is a server installed with other operating systems, what is more, the monitored object is not a server, but just a switch or router. Therefore, if zabbix wants to be able to monitor these objects comprehensively, it needs to be able to communicate with them through various methods.

 

So what communication methods can zabbix support, summarized as follows:

  • Agent: Monitor through a dedicated agent program, similar to the common master/agent model. If the monitored object supports the corresponding agent, this method is recommended.
  • ssh/telnet: communicate through remote control protocols, such as ssh or telnet.
  • SNMP: Communicate with the monitored object through the SNMP protocol. The full name of the SNMP protocol is Simple Network Management Protocol, which is translated as "Simple Network Management Protocol". Generally speaking, we cannot install agents on hardware such as routers and switches, but These hardwares often support the SNMP protocol. SNMP is a relatively old and popular protocol. Most network devices support this protocol. In fact, the working mode of the SNMP protocol can also be understood as the working mode of the master/agent. The SNMP agent is built into these devices, so most network devices support this protocol.
  • IPMI: Monitoring through the IPMI interface, we can monitor the physical characteristics of the monitored object, such as voltage, temperature, fan status, power supply status, etc., through the standard IPMI hardware interface.
  • JMX: Monitoring through JMX, JMX (Java Management Extensions), when monitoring JVM virtual machines, this method is also a very good choice.

 

Well, we mentioned zabbix agent just now. Generally, we deploy zabbix agent to the monitored host. The agent collects data and reports it to the central host responsible for monitoring. The central host is the master in the master/agent model. The central host responsible for monitoring is called zabbix server. Zabbix server stores the information received from the agent side in the zabbix database. We call the zabbix database side as zabbix database. If the administrator needs to view various monitoring information, Need zabbix GUI, zabbix GUI is a kind of Web GUI, we call it zabbix web, zabbix web is written in php, so if you want to use zabbix web to display relevant monitoring information, you need to rely on the LAMP environment, whether it is zabbix server, or zabbix web, they all need to connect to zabbix database to get related data, so it may not be easy to understand, it is much easier to understand the above concepts compared with the following figure

                                                                                          Zabbix from giving up to getting started (1): zabbix concept

 

When the monitoring scale becomes huge, we may have thousands of devices to monitor. At this time, do we need to deploy multiple zabbix systems for monitoring?

If multiple sets of zabbix monitoring systems are deployed, the monitoring pressure will be shared, but these monitored objects will be distributed as evenly as possible to different monitoring systems. At this time, we cannot monitor through a unified monitoring portal. With these objects, although the monitoring pressure is shared, it also increases the complexity of the monitoring work. So, should we build multiple zabbix monitoring systems to share the huge monitoring pressure? In fact, because zabbix is ​​born with the ability to deal with this kind of problem, zabbix supports distributed monitoring, we can divide thousands of monitored objects into different areas, and set up a proxy host in each area. The information of each monitored object is collected by the agent and submitted to the proxy host. In this area, the proxy host acts like a zabbix server. We call these proxy hosts zabbix proxy, and zabbix proxy submits the collected information to Real zabbix server processing, in this way, zabbix proxy amortizes the pressure of zabbix server, and at the same time, we can also monitor all objects through a unified monitoring portal. When the monitoring scale is large enough to use zabbix proxy, the architecture of zabbix is ​​as shown below, We can compare the following figure to understand the above description.

                                                                                   Zabbix from giving up to getting started (1): zabbix concept

 
 

Here, we will summarize the various components just mentioned:

  • zabbix agent: deployed on the monitored host, responsible for the data of the monitored host, and send the data to the zabbix server.
  • zabbix server: Responsible for receiving the report information sent by the agent, and for organizing configuration information, statistical information, operating data, etc.
  • zabbix database: A database used to store all zabbix configuration information and monitoring data.
  • zabbix web: The web interface of zabbix. The administrator can manage zabbix configuration and view zabbix related monitoring information through the web interface, which can be deployed on a separate server.
  • zabbix proxy: optional component, used in a distributed monitoring environment, zabbix proxy represents the server side, completes the collection of information in a local area, and finally sends it to the server side uniformly.

After understanding several core components of zabbix, let's talk about the working mode of zabbix.

We know that the agent will actively send the collected data to the server. This mode is called the active mode, which is active for the agent.

In fact, the agent side can also not actively send data, but wait for the server to come and pull data. This mode is called passive mode.

As smart as you must have already understood, whether it is active mode or passive mode, it is for the agent side, and the active mode and passive mode can exist at the same time without conflict.

The administrator can use a tool called zabbix_sender on the agent side to test whether it can send data to the server side.

The administrator can use a tool called zabbix_get on the server side to test whether it can pull data from the agent side.

 

Well, we have understood some basic concepts of zabbix. In fact, zabbix still has many commonly used terms, but now we have not encountered actual usage scenarios. The description of the empty vernacular is particularly weak and difficult to understand, so we just ignore them. We will explain when we use them.

Guess you like

Origin blog.csdn.net/qq_35995514/article/details/110402619
Recommended