1
edit
Changes
no edit summary
1. To install the nrpe daemon and nagios plugins run the following commands.
<code>yum –y install nrpe yum -y install Nagios-plugins-all</code>
2. Open nrpe.cfg and edit it with your favourite editor.
Add an allowed_hosts IP Address to nrpe.cfg file eg. 142.204.133.123 (chile’s IP Address):
3. Test the nrpe daemon locally using the command:
<code>netstat -at | grep nrpe</code>
tcp 0 0 *:nrpe *:* LISTEN
4. Add a firewall rule to the INPUT chain
5. Save the firewall settings so it survives reboot
<code>/etc/nrpe.d nagios/<code> -> contains the daemonnrpe.cfg
<code>/usretc/lib64nrpe.d</nagios/plugins code> -> contains all plugins added during installthe daemon
<code>/usr/sbinlib64/nagios/plugins</nrpe code> -> contains the nrpe execution fileall plugins added during install
<code>/usr/sharesbin/docsnrpe</nrpe-2.12 code> -> contains the related README, Changelog files and .pdf etcnrpe execution file
<code>/usr/share/docs/nrpe-2.12</code> -> contains the related README, Changelog files and .pdf etc
</pre>
6. Check to make sure the NRPE daemon is functioning properly. To accomplish this, run the check_nrpe plugin that was installed for testing purposes. The directory make be different depending OS.
Or
7. Some of these commands can be executed on the Remote host for testing daemon functionality
<code>/usr/local/nagios/libexec/check_nrpe -H localhost -c check_load</code>
<code>/usr/local/nagios/libexec/check_nrpe -H localhost -c check_hda1</code>
<code>/usr/local/nagios/libexec/check_nrpe -H localhost -c check_total_procs</code>
<code>/usr/local/nagios/libexec/check_nrpe -H localhost -c check_zombie_procs</code>