Nagios 4 : Add Monitoring Target Item2021/06/03 |
It's possible to add monitoring Target Items. There are many RPM packages for them.
Or it's possible to create a plugin by yourself. And also there are many plugins provided by comunity below. ⇒ http://exchange.nagios.org/ |
|
[1] | Many plugins are provided with RPM packages like follows. |
# use EPEL repo [root@dlp ~]# dnf --enablerepo=epel search nagios-plugins- nagios-plugins-nt.x86_64 : Nagios Plugin - check_nt nagios-plugins-ntp.x86_64 : Nagios Plugin - check_ntp nagios-plugins-ssh.x86_64 : Nagios Plugin - check_ssh nagios-plugins-all.x86_64 : Nagios Plugins - All plugins nagios-plugins-apt.x86_64 : Nagios Plugin - check_apt nagios-plugins-dbi.x86_64 : Nagios Plugin - check_dbi nagios-plugins-dig.x86_64 : Nagios Plugin - check_dig nagios-plugins-dns.x86_64 : Nagios Plugin - check_dns ..... ..... nagios-plugins-disk_smb.x86_64 : Nagios Plugin - check_disk_smb nagios-plugins-file_age.x86_64 : Nagios Plugin - check_file_age nagios-plugins-ifstatus.x86_64 : Nagios Plugin - check_ifstatus nagios-plugins-mrtgtraf.x86_64 : Nagios Plugin - check_mrtgtraf nagios-plugins-ide_smart.x86_64 : Nagios Plugin - check_ide_smart nagios-plugins-ifoperstatus.x86_64 : Nagios Plugin - check_ifoperstatus nagios-plugins-remove_perfdata.x86_64 : Nagios plugin tool to remove perf data |
[2] | For example, add [check_ntp] plugin to monitor time difference between the System time and NTP Server. |
[root@dlp ~]#
dnf --enablerepo=epel -y install nagios-plugins-ntp
[root@dlp ~]#
vi /etc/nagios/objects/commands.cfg # add follows to the end define command { command_name check_ntp_time command_line $USER1$/check_ntp_time -H $ARG1$ -w $ARG2$ -c $ARG3$ }
[root@dlp ~]#
vi /etc/nagios/objects/localhost.cfg # add to the end # Warning with 1 sec time difference, Critical with 2 sec difference define service { use local-service host_name localhost service_description NTP_TIME check_command check_ntp_time!ntp.nict.jp!1!2 notifications_enabled 1 } systemctl restart nagios |
[3] | It's possible to view the status for a new plugin on the admin site. |
Sponsored Link |