Page 1 of 2

How to monitor machines with different subnets in nagios

Posted: Tue Jun 09, 2015 3:21 pm
by Jessuzz94
Hi good morning, i have Nagios 4 and i am testing monitoring switches and servers, but in a local network, i mean , all devices (switches, routers, servers) has in the same network (192.168.1.0), but im going to implement the nagios server in one Site with a lot of servers and routers to monitor, my question is, how to see the other subnets to monitor the devices in my nagios server? for example all the machines in the sites are in one private network, (ex. 10.1.0.0) how to see other machines if my nagios is 10.1.10.0 and other machines are 10.1.4.0, 10.1.5.0 ....

Thanks !

Re: How to monitor machines with different subnets in nagios

Posted: Tue Jun 09, 2015 3:35 pm
by jdalrymple
If the networks are routable then it's a trivial task. If they're not (and I'm assuming they aren't) our distributed monitoring options are kind of as follows and documented fairly well:

1) Passive checks (Nagios needs to be routable itself)
2) Use an NRPE service as a springboard into the remote networks
3) Use a remote Nagios instance and submit passive checks, not much different than option 1
4) Put a gearman worker in the remote networks
5) Use a Fusion server to aggregate the results of multiple distributed Nagios instances

This is the document we published for performing this task with our commercial product:
https://assets.nagios.com/downloads/gen ... utions.pdf

At the end of the day there is no 1 solution, and realistically the problem is a matter of layer 3 and 4 transport moreso than an upper layer software problem. How you choose to solve those problems is kind of up to you, but the list above helps to simplify.

Re: How to monitor machines with different subnets in nagios

Posted: Tue Jun 09, 2015 3:40 pm
by ssax
In addition to jdalrymple's answer, if your asking about basic routing, your router/switch/firewall would usually grant the ability to access different subnets, you basically need a route.

Nothing needs to be done on the XI server, you could technically add another network card that is on the subnet and handle it that way but really the above solution is how most organizations handle it.

Re: How to monitor machines with different subnets in nagios

Posted: Thu Jun 11, 2015 11:30 am
by Jessuzz94
Oh okay, so, if the networks isn“t routable, the best solution is to use passive checks?, or what solution is more efficent for you. Thanks!

Re: How to monitor machines with different subnets in nagios

Posted: Thu Jun 11, 2015 12:05 pm
by abrist
If nagios cannot route to the subnet, but the subnet can route to the nagios server, passive checks are your *only* option.

Re: How to monitor machines with different subnets in nagios

Posted: Thu Jun 11, 2015 12:54 pm
by Jessuzz94
And if nagios cannot route, or ping to the subnet and cannot route or ping the subnet to the nagios, what can i do?

Re: How to monitor machines with different subnets in nagios

Posted: Thu Jun 11, 2015 12:58 pm
by tmcdonald
Is there an intermediary host that can talk to both networks? You could proxy in the traditional sense, or use something like NRPE which fulfills roughly the same purpose.

Re: How to monitor machines with different subnets in nagios

Posted: Thu Jun 11, 2015 1:05 pm
by Jessuzz94
how proxy in traditional sense?,

The test i am doing is that i have one switch, one ubuntu server client and other ubuntu server with the nagios,they are connected to the switch. In the ubuntu server client i putted the address 192.168.2.10, and my ubuntu nagios server has the 192.168.1.10, how i can ping it or see the ubuntu server client?, with passive checks?, for example configuring NSCA?

Re: How to monitor machines with different subnets in nagios

Posted: Thu Jun 11, 2015 1:19 pm
by ssax
Are you really just looking to establish network connectivity between the two? If so, you need to setup a route on your switch so that one subnet can talk with the other subnet.

It doesn't really sound like you are looking to proxy, you just want them to be able to communicate, right? Passive checks will not fix the problem if your client cannot communicate with the XI server on the network.

Passive checks mean Client to XI Server.
Active checks mean XI Server to Client.

But if there is no route for either of the servers to communicate with eachother and/or no other server that can access both to use as a proxy, then it won't work until you establish network communication.

Re: How to monitor machines with different subnets in nagios

Posted: Thu Jun 11, 2015 1:27 pm
by Jessuzz94
Then, if in the Site all servers and routers are connected to switches and have a route protocol and they can ping to my nagios server, i will need pasive checks?

If nagios can ping the devices too, the monitoring config will be easy not?