Trouble With Remote Host Monitoring


So, this is my first time installing Nagios, so forgive me if this is a little rudimentary. I installed nagios to run as the nrpe daemon on the remote server and then the nagios stuff on the monitoring server. I can get stats through nagios running commands on the server on which I’m monitoring. However, it appears (through the web interface) that I’m actually monitoring 2 instances of the localhost. Does anyone have any ideas where I might be going wrong? I set up a remotehost.cfg file and I think the problem might be with groups?? I have no idea.


I’m confused by your wording. It sounds like you are running nrpe on the remote server, nagios isn’t monitoring it, but instead monitoring the local server twice. Did you setup 2 separate hosts? One local and one remote? Make sure that your templates don’t contain default host_name and address definitions. You want to define those in your hosts config. You should have the following.

define host {
name generic-host
check_command check-host-alive
max_check_attempts 1
check_interval 0
check_period 24x7
active_checks_enabled 1
flap_detection_enabled 1
process_perf_data 1
retain_status_information 1
retain_nonstatus_information 1
notification_interval 1
notification_period 24x7
notifications_enabled 1
register 0
notification_options d,u,r
hostgroups default

define host {
use generic-host
host_name host1
contact_group admins

define host {
use generic-host
host_name host2
contact_group admins