>From the Fields tab of the event: Field Value dedupid mmc-sansw2.domain.dom||/Storage/SAN||4|snmp trap swFCPortScn evid 36a9f9b8-fe66-452c-ae76-a4cdddee873a device mmc-sansw2.domain.dom
>From the Details tab of the event: Field Value community zenoss oid 1.3.6.1.4.1.1588.2.1.1.1.6.2.1.38.12 swFCPortFlag 0 swFCPortIndex 12 - Justin jmp242 wrote: > Does the event have swFCPortIndex ? In an example event, does evt.device > actually equal what you're testing against - is it using that name for > the device? > -- > James Pulver > Information Technology Area Supervisor > LEPP Computer Group > Cornell University > > > > jbwjbw wrote, On 9/10/2009 9:02 AM: > > > Ok, I should have had evt._action = 'history'. I can fix that. It did not > > delete the event or change the severity when the trip came last night so > > something else is wrong with my code. Anyone have any ideas? > > > > Thanks, > > > > - Justin > > > > > > jmp242 wrote: > > > > > Well, evt._action = 'drop' isn't going to put the event in history, but > > > delete it entirely. > > > See: > > > http://community.zenoss.org/trac-zenpacks/wiki/CommunityFAQGeneral?version=98#Whatre-mappingoptionsarethereforeventsinEventTransforms > > > -- > > > James Pulver > > > Information Technology Area Supervisor > > > LEPP Computer Group > > > Cornell University > > > > > > > > > > > > jbwjbw wrote, On 9/10/2009 8:19 AM: > > > > > > Josh, > > > > > > I'm trying to build on this for different event transform, any guidance? > > > > > > I have two fiber channel switches that sends a trap because a system > > > connected to tem reboots nightly after it's backup is complete. I only > > > want to do this when swFCPortIndex equals 12 from the snmp trap details > > > for two specific swtiches. I'd like to change the event to blue and move > > > it to the history. I need to key off a specific value in the snmp details. > > > > > > > > > Code: > > > > > > theswFCPortIndex = getattr(evt, 'swFCPortIndex', 'Unknown') > > > > > > if (evt.device == 'mmc-sansw1.domain.dom' or evt.device == > > > 'mmc-sansw2.domain.dom') and theswFCPortIndex == '12' : > > > evt.severity = 1 > > > evt._action = 'drop' > > > > > > > > > > > > > > > This code is not quite right, and I figured it might not be. Any chance > > > someone can let me know what I'm doing wrong? > > > > > > Thanks!! > > > > > > - Justin > > > > > > > > > > > > > > > > > > > > > > > > _______________________________________________ > > > zenoss-users mailing list > > > [email protected] > > > http://lists.zenoss.org/mailman/listinfo/zenoss-users > > > > > > > > _______________________________________________ > > zenoss-users mailing list > > [email protected] > > http://lists.zenoss.org/mailman/listinfo/zenoss-users > > > > > > > > > _______________________________________________ > zenoss-users mailing list > [email protected] > http://lists.zenoss.org/mailman/listinfo/zenoss-users > _______________________________________________ zenoss-users mailing list [email protected] http://lists.zenoss.org/mailman/listinfo/zenoss-users[/quote] -------------------- m2f -------------------- Read this topic online here: http://forums.zenoss.com/viewtopic.php?p=39148#39148 -------------------- m2f -------------------- _______________________________________________ zenoss-users mailing list [email protected] http://lists.zenoss.org/mailman/listinfo/zenoss-users
