Monitoring remote network resources (from diff. IP domains)


#1

Hello everyone!
I’m Nagios newbie and have some doubts.
What am i doing? I have nagios host that is doing active checks for the hosts it can reach and is doing some checks via nsclient on remote hosts for the hosts it can’t reach directly. so, i made the config like that:

define host{
use generic-host
host_name my-distant-host
alias Distant host @ Khabarovsk

address 10.216.4.42

check_command  check-dist-host!10.216.4.42!50,100!1500,2000
check_interval    3
max_check_attempts  10
notification_interval     120
notification_period     24x7
notification_options    d,u,r
contact_groups          admins

}
The command check-dist-host looks like
define command{
command_name check-dist-host
command_line $USER1$/check_nrpe2 -H 192.168.11.8 -c check_dist_host_alive!$ARG1$!$ARG2$!$ARG3$
}

192.168.11.8 is the host, that is actually performing ping with the perl check_ping.pl script.
I commented out the address field because i used to get a lot of flapping, because (as far as think) nagios checks whether host is alive in some extra way other than check_command. With address field commented it works well. but i think it’s not the right way of doing things in nagios.
Any ideas? How do you resolve these situations of monitoring different network resources across the network?. I thought of distributed monitoring, but unfortunetly i don’t have any *nix hosts in 192.168.0.0 network to put nagios on it. And i don’t want to make any holes on my firewalls and routers to route all these dummy networks…
Any help would be great!


#2

P.S. I must mention that this scheme is working for me, but i think it’s not the right way to do it. I’m not quite sure why it’s not right, just some doubts…