Monitoring routers with two interfaces


#1

Hello,

How i can monitoring with Nagios - routers with two or more interfaces.
First interface may be down and router working with second interface with another ip.

I can define two or more ip for device ?

thanks


#2

You can write a bash script (plugin) that would check both interfaces and return down state only when both interfaces are down, otherwise the srcipt returns ok status. When you write a script that would check that, you should also define both IP addresses in check_command definition. In host definition for that router for check-host-alive you then define the script you wrote.

Tip. Take a look in documetation for creating new plugins, and pay attention to the exit codes, 'cause Nagios host state depends on those.