cancel
Showing results for 
Search instead for 
Did you mean: 

XMC monitoring philosophy

XMC monitoring philosophy

Dan15
Contributor
I'm currently evaluating and as far as I see XMC is relaying on data what are sent by devices either with syslog or snmp trap. I know that XMC is snmp polling the device for status and interfaces. Is it also possible to snmp poll a specific OID and raise an alarm if the returned value does not match the definition?

Regards

Dany
7 REPLIES 7

M_Nees
Contributor III
Hi Dany,

normally errors which stay longer like fan or PSU failures will be reported via trap serveral times within a fixed interval.
So if you loose one message the next will come few seconds or minutes later.

Regards

Dan15
Contributor
Hey thanks for your answers and the script template!
Our current monitoring system is mainly based on snmp status alarming. I'm considering to change towards syslog and trap alarming, because the effort to maintain all the monitors for different devices is huge. I'm only worried that syslog or traps might get lost in transport. For example you have a power supply failure and the device is sending a syslog or trap (udp) and the massge gets lost, you will probably never notice that. What are your opinions and experiences?

StephanH
Valued Contributor III
Hello Dany,

here a short working Python example, running directly on an XMC Ubuntu installation (not on Windows!!!) without additional Python modules.
You will find a corresponding entry in you syslog on XMC, have a look.


code:
import commands

#Change OID as you need. Here we request the SysContact.
commando = "/usr/bin/snmpget -v3 -u username -l authPriv -a SHA -x AES -X password -A password switchip 1.3.6.1.2.1.1.4.0"

ans= commands.getoutput(commando)

print(ans)

alarm = commands.getoutput("logger" + " " + ans)

print(alarm)


Have fun.

Regards
Stephan
Regards Stephan

StephanH
Valued Contributor III
Hello Dany,

I agree with M. Nees. This function does not exist at the moment.
But you can create a small script to check the oid and create an syslog entry if you receive a value not matching your definition.

That syslog event can trigger an alarm, too.

Regards
Stephan
Regards Stephan
GTM-P2G8KFN