Connect & Share

How to add targeted Host in Nagios

Previously We learned about installing the nagios. Today, we will learn how to add targeted host in Nagios in other word adding another server or other hosts, which lives or server is ping or not. If you want to monitor various services on other hosts, then you need to install NRPE agent on target host. We know Nagios is best monitoring tools and nagios offers monitoring and alerting for servers, switches, application, and services. It alerts users when things go wrong and alerts them again when the problem has been resolved. This is the time to add some stuff in nagious. Adding targeted host in nagios is very important but it can be a bit tidy.

How to add targeted Host in Nagios?

1) This syntax example shows to add a target " []". [root@master ~]#chgrp nagios /etc/nagios/servers [root@master ~]#chmod 750 /etc/nagios/servers [root@master ~]#vi /etc/nagios/servers/node01.cfg # create new define host{ use linux-server host_name node01 alias node01 address } define service{ use generic-service host_name node01 service_description PING check_command check_ping!100.0,20%!500.0,60% } [root@master ~]#/etc/rc.d/init.d/nagios restart Running configuration check...done. Stopping nagios: .done. Starting nagios: done. 2) You can access Nagios admin site and confirm the target hosts added or not.

Leave a Reply