Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to realize client Monitoring in nagios

2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >

Share

Shulou(Shulou.com)06/02 Report--

This article mainly introduces how to achieve client-side monitoring in nagios. The article is very detailed and has certain reference value. Interested friends must read it!

Client monitoring:

In this demonstration, the three ways to monitor clients mentioned earlier are:

Method 1: SNMP

Server IP: 192.168.100.133

Client IP: 192.168.100.132

Restart client snmpd

The server-side snmp command gets client-side correlation values

Take the client's load value of 1 minute, 5 minutes and 15 minutes as an example

On this basis, we can use nagios plugins

Method 2: nrpe(here, the disk command is detected as an example)

In order to pass parameters to this method, we have added argument when compiling before; so we can make parameters on the server side,

For example:

Modify client nrpe.conf

Turn on Allow Transfer Parameters

vim /usr/local/nagios/etc/nrpe.cfgdont_blame_nrpe=1

Edit files to allow remote operations on the server side;

vim /usr/local/nagios/etc/nrpe.cfg

allowed_hosts=192.168.100.190command[check_disk]=/usr/local/nagios/libexec/check_disk -w $ARG1$ -c $ARG2$ -p $ARG3$

Initiate nrpe

/usr/local/nagios/bin/nrpe -c /usr/local/nagios/etc/nrpe.cfg -d

Testing on the server side:

[nagios@masterlibexec]$ ./ check_nrpe -H 192.168.100.134 -c check_disk -a "20%" "10%""/boot"

You can see that the server controls our target requirements at will

Method 3: SSH

Write your own script to get;

Method 4: Write an agent. socket fetch;

The main way to obtain is the above four ways

The above is "how to achieve client monitoring in nagios" all the content of this article, thank you for reading! Hope to share the content to help everyone, more relevant knowledge, welcome to pay attention to the industry information channel!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Development

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report