![]() |
![]() |
Subject: | Event Class mapping not working as expected. |
Author: | [Not Specified] |
Posted: | 2015-07-24 09:19 |
Hi Team,
I am working on creating a transformation to receive a Trap from a NNMI management tool and assign it to an event class.
I have a created an event class NNMI and NNMIAlerts, so its /Events/NNMI/NNMIAlerts so within NNMIAlerts i have created a event class mapping as nnmiTraps.
Within this eventclass mapping i have created a rule as below:
getattr(evt,'oid').startswith(('1.3.6.1.4.1.11.2.17.19.2'))
and applied simple transform to get attributes of OID and put a debug to print it in event.log file.
Based on the trap I am receiving, I expect the rule to work and assign the alert to this event class. However this trap is being alerted on /Unknown event class and its obvious i cant see log printed to pick OID.
Please let me know whats the issue here.
Thank you,
Gowrish
Subject: | grab the event and transform |
Author: | Andrew Kirch |
Posted: | 2015-07-24 15:57 |
grab the event and transform it to the class you're wanting. http://wiki.zenoss.org/Category:Transforms
Andrew Kirch
akirch@gvit.com
Need Zenoss support, consulting or custom development Look no further. Email or PM me!
Ready for Distributed Topology (collectors) for Zenoss 5 Coming May 1st from GoVanguard
Subject: | Hi Andrew, |
Author: | [Not Specified] |
Posted: | 2015-07-29 08:44 |
Hi Andrew,
I checked, seems none of these rules are gabbing traps and assigning the event class.
getattr(evt,'oid').startswith(('1.3.6.1.4.1.11.2.17.19.2'))
getattr(evt,'oid','').startswith(('1.3.6.1.4.1.11.2.17.19.2'))
All are faining any pointers.
Subject: | For starters, is there a MIB |
Author: | Jane Curry |
Posted: | 2015-07-30 09:17 |
For starters, is there a MIB available that describes these TRAPs If so, you might start by importing that in to Zenoss as it will at least help decode the ASN.1 numerical gobbledegook into some basic words. If the MIB is imported, it will probably change your transform as you will probably find that the OID starts with enterprises. - in other words, some translation will occur.
The next question is your version of Zenoss. With Zenoss 3.x then your code may work but with Zenoss 4 and later the structure of the event fields changed. Grab my Event Management paper from http://www.skills-1st.co.uk/papers/jane/zenoss4-events/ and have a look around page 104 for examples decoding TRAP varbind event attributes.
Cheers,
Jane
Email: jane.curry@skills-1st.co.uk Web: https://www.skills-1st.co.uk
Subject: | Hi Jane, |
Author: | [Not Specified] |
Posted: | 2015-08-11 05:20 |
Hi Jane,
Thank you for your help, I managed that to get worked by defining the eventclass key as defaultmapping. But although i am not testing any tarps to match this condition all times i can see my zenevend.log filled with below message every 5 minutes without me testing this rule. Could you please let me know what could be the reason.
2015-08-11 15:44:47,901 WARNING root: EventClassInst: /NNMI/NNMIAlerts/NnmiTraps rule failure: oid
2015-08-11 15:44:56,249 INFO zen.maintenance: Performing periodic maintenance
2015-08-11 15:44:58,072 WARNING root: EventClassInst: /NNMI/NNMIAlerts/NnmiTraps rule failure: oid
2015-08-11 15:45:56,252 INFO zen.maintenance: Performing periodic maintenance
2015-08-11 15:46:56,258 INFO zen.maintenance: Performing periodic maintenance
2015-08-11 15:47:18,037 WARNING root: EventClassInst: /NNMI/NNMIAlerts/NnmiTraps rule failure: oid
2015-08-11 15:47:56,265 INFO zen.maintenance: Performing periodic maintenance
2015-08-11 15:48:08,078 WARNING root: EventClassInst: /NNMI/NNMIAlerts/NnmiTraps rule failure: oid
Thank you,
< |
Previous The threshold high utilization in template ethernetCsmacd has caused an exceptio ... |
Next Kerberos errors while modelling |
> |