Ad Widget

Collapse

add binary AND operator to trigger expressions

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • dvd
    Junior Member
    • Dec 2005
    • 6

    #1

    add binary AND operator to trigger expressions

    we have monitoring device with 8 digital inputs, which can be either 0 or 1.
    Device gives its state through SNMP as one-byte integer, and it is impossible (or will require overly long expression, because all math done with floating point numbers) to distinguish individual bits in this integer , and we need to check individual inputs on this device. So we decided to add binary AND operator to trigger expressions. Changes done to expression.c (just copied code for another operator and made slight changes) , and to config.inc.php of frontend to allow using this operator in expressions written there.

    we used '@' as designator of AND operation, so to get bit 4, you just need to use: value@16

    patch attached. apply whith patch -p1 in zabbix-1.1beta2 directory.
    Attached Files
    Last edited by dvd; 13-12-2005, 09:45.
Working...