Because of work requirements, I often use a tool in Linux:Nagios
Figure-Nagios
Use Nagios to monitor the network of servers on the network
1. Implementation Principle
Various servers in the network need to be managed and maintained, and the administrator cannot monitor the status of each server in a timely manner. At this time, the software function is required. Nagio
Toss for 2 days. The Nagios 4.x version of the monitor server lasts about 3-4 months. Originally set up when they want to do a map of the monitoring, but has not been out. And then it was put on hold. Before, because of server performance problems, want to analyze, so there is such a demand. After 2 days of fighting, finally put the nagios out of the picture. Her
NagiosStartup and detection are as follows:
Figure-Nagios
1. Check Configuration: Nagios verification is very accurate. If you cannot start nagios correctly, you can find the answer from the error output.
/Usr/local/nagios/bin/nagios-v/usr/local/
Nagios's monitoring principle: actually very simple. We have installed the Nrpe service on the server side, then all the client data is collected through this Nrpe and uploaded to the Nagios server, which is called by Nagios to generate.Working process:(1) The client has defined, in the Nrpe.cfg file, the way the module is called or the
[Tool Development] keepalived uses the nagios monitoring script, keepalivednagios
Recently, keepalived and keepalived are used in the development and office environments. Based on the LVS supported by the Linux kernel, keepalived achieves high availability and load balancing, which is very practical.
Keepalived can be used to monitor service status in multiple ways, such as HTTP_GET | SSL_GET | TCP_CHECK |
1. Package the configuration file of a configured Nagios client, upload it to the client that needs to be configured, and unzip it.#注意客户机环境的准备工作!#在两台服务器相差无几的情况下, eliminating the installation steps, simple and efficient.#注意权限问题!2, the client configuration side configured to run the service side detection of the IP address as follows:Vi/usr/local/nagios/etc/nrpe.cfg +79allowed_hosts=127.0.0.1,10.0.0.22#多个服务地址
I. Custom Nagios monitoring scripts1. Create a script on the client/usr/local/nagios/libexec/check_disk.shVim/usr/local/nagios/libexec/check_disk.sh writes the following: (On the client)#!/bin/bashrow= ' df-h |wc-l ' #输出的总行数For i in ' seq 2 $row ' #从第二行开始为真实的磁盘 because the first behavior header informationDoAva= ' df-h
Create a script on the client/usr/lib/nagios/plugins/check_disk.sh//yum installation of Nagios, if you are compiling the default script file directory for your own installation in a custom installed Nagios directoryTo operate on the client:vim/usr/lib/nagios/plugins/check_disk.sh writes the following://This is a disk s
Note: There is a file embedded within this post, please visit this post to download the file.The data center does not have a temperature alarm device. I use this method to control the temperature of the data center. If there is only one alarm, a single machine failure can be considered. If there are several alarms at the same time, it can be considered that there is a problem with the air conditioner in the data center.
The specific implementation method is as follows:
Environment: monitored: Ce
/init.d/nrpe restartService side5. Check if the script is running correctly[email protected] ~]#/usr/lib64/nagios/plugins/check_nrpe-h 192.168.219.128-c check_disk/OK 26% 13g/dev/shm ok 0% 242m/boot OK 8% 426MExplanatory notes:If normal, it will output a row of disk detection data, or may be error.# # # # #错误 #####[Email protected] ~]#/usr/lib64/nagios/plugins/check_nrpe-h 192.168.153.129-c check_diskNrpe:u
From the initial Nagios to the now powerful Zabbix 3.0, I would say that no performance-based development and monitoring are all nonsense?First of all, I am aware of these two monitoring software:Zabbix, a lot of enterprises are in use, give a person's feeling is very dazzling, but I personally think that although it is powerful, can draw a cool image, but in you
Our network and servers should be carefully looked after, otherwise you will have a lot of trouble or find a tool to help us manage these people care about the machine----Nagios
Here a simple configuration of the monitoring host, in-depth configuration needs a lot of learning, online information a lot
The following simple write out my own configuration, maybe there is a wrong place, please point out, than
1. About Nagiosis an open source software that can monitor network device network traffic, linux/windows host status, and even monitor the printerIt can run on Linux or on WindowsBrowser-based web interface makes it easy for operations personnel to view the status of monitoring itemsSupport Web interface configuration, management operationsSupport SMS, email notificationCustomizable scripting enables custom monitoringNagios official website http://www
After SSH login through the background ESXI5.5, cd/etc/vmware into the directory: 650) this.width=650; "Src=" http://s1.51cto.com/wyfs02/M00/8C/73/ Wkiom1hstq3cpgdsaabwhyilons782.png-wh_500x0-wm_3-wmp_4-s_611287355.png "title=" qq picture 20170104164712.png "alt=" Wkiom1hstq3cpgdsaabwhyilons782.png-wh_50 "/>The LS command looks at the snmp.xml configuration file under this directory,VI Snmp.xmlModify the configuration file toAfter the modification, restart the
NagiosServer SelfMonitoringThere are two methods for implementation, which can be simple!
Figure-Nagios
Self-monitoring implementation of Nagios Server
To monitor resources and services, you must configure the nagios server and the NRPE-nagios remote plugin
Executor)
Before we write the monitoring plug-in, we first need to have some idea of the Nagios monitoring principle.Nagios's function is to monitor the service and host, but he does not include this part of the function, all the monitoring, detection functions are through a variety of plug-ins to complete.When
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.