On May 13, 2008, at 8:37 AM, Peccoux wrote:
I have a problem with event commands that I defined in Event
Manager. I would like to run specific rules when an eventclass
appears.
Ex :
- First rule : my event filter is
(eventClass != '/HW/Disk' or eventClass != '/HW/Power' or
eventClass != '/Status/OSProcess' or eventClass != '/Status/Snmp')
and (severity >= 4)
-Second rule :
(prodState = 1000) and (eventClass = '/HW/Disk') and (severity >= 4)
So, if I understand zenoss rules, when an eventclass = "/HW/Disk"
appears, it's my second rules that zenoss chooses. Otherwise, if
event class is neither /HW/Power' nor '/Status/OSProcess' nor '/
Status/Snmp', then it 's my first rules that zenoss chooses.
However, this situation doesn't work because when an eventclass
equal to /HW/Disk', it's the first rule that zenoss chooses. So, I
solve my problem thanks to zope interface (/zport/dmd/
ZenEventManager/commands/<command_name>/manage) and I replace in
first rule OR by AND :
before :
(eventClass != '/HW/Disk' or eventClass != '/HW/Power' or
eventClass != '/Status/OSProcess' or eventClass != '/Status/Snmp')
after :
(eventClass != '/HW/Disk' and eventClass != '/HW/Power' and
eventClass != '/Status/OSProcess' and eventClass != '/Status/Snmp')
Is it normal that I can't change it in zenoss interface ?
Do you have the same problem ?
This is a known limitation with the UI always assuming that you're
doing OR operations. As you've very clearly stated this doesn't work
at all for multiple != comparisons. See the following ticket for this
issue.
Ticket #2298: AND comparisons against the same value in the Event
Filter GUI
http://dev.zenoss.org/trac/ticket/2298
_______________________________________________
zenoss-users mailing list
[email protected]
http://lists.zenoss.org/mailman/listinfo/zenoss-users