Externally monitoring OSPF neighbor states?

I need some method to monitor OSPF states and report on them. At the moment we only receive log messages as they happen - but these are easily missed when the state change was at 3am and a bunch of other log messages have come through before open of business. So if the router has a backup connection it can go noticed until someone complains of slow speeds and we realize the primary has been down for X days. I would rather have alerts every 10 minutes if an OSPF neighbor adjacency has gone down until it is rectified

Is there any way to monitor OSPF neighbor states from an external monitoring platform? Cisco and some other vendors allow this via an SNMP OID but I can’t find any OID’s on RouterOS for OSPF at all
Otherwise are environment variables pollable through an SNMP OID? As then maybe I can script something to run periodically and store the state of all known neighbor states since reboot
Alternatively can it be done via an API call?

If anyone is successfully monitoring OSPF states i’d be interested in hearing how

You can monitor OSPF states via API.

We’re running a script-based approach since MT hasn’t implemented SNMP for OSPF LSA yet (only for BGP). Check out “OSPF SNMP monitoring” in the “Routing Protocol Overview”.

I found this post because I’ve been sniffing out solution ideas along similar lines for my company. EG: what are other people doing to monitor OSPF or changing IP routes?

My plan B (which I’m researching any low hanging fruit to try first) is to SNMP poll for changes in the IP routes. For our use case, I’m more interested in the IP routes changing than the OSPF anyway because loss of OSPF will move the IP routes meaning we would still detect that, but also because sometimes IP routes get messed up even while OSPF adjacencies remain online so tracking that is more robust anyway.

The IP routes can be monitored via IP-FORWARD-MIB::ipForward = .1.3.6.1.2.1.4.24, so I’ll script something to poll that if I can’t find any obvious, simpler strats that folk can recommend. :slightly_smiling_face:

hi @mrz

any chance for SNMP ?
every device in our network have nice OSPF status/monitoring in LibreNMS/Observium
only ccr2216 is …. well, blank page :frowning:

it will be nice to have this SNMP info

Any update or intentions to update this? As the network grows it's becoming a larger problem where link interruptions can go unnoticed for an unacceptably large period of time. Usually when a backup link fails, everything appears to work fine until the primary also fails

API is extremely not great. Standard SNMP monitoring of OSPF would work with existing monitoring platforms and not require custom coding for API integration

That said if anyone has done this and has published the resources i'd like to know of it