Ad Widget

Collapse

Trigger Expressions

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • PBG
    Junior Member
    • Jun 2005
    • 2

    #1

    Trigger Expressions

    Hi,
    Just wondering if Zabbix supports more than one item in an arithmetic expression. I'm looking to do the following...

    {HOST1:filesize[C:\fileone.dat].last(0)}+{HOST1:filesize[C:\filetwo.dat].last(0)}-{HOST2:syslog[exchws].last(0)}>16000000000

    I get ERROR:Invalid trigger expression when I try to add it.

    I'm trying to monitor the size of a Microsoft Exchange database, which requires the size of two files to be added together and then the whitespace in those files to be subtracted. So, DBFile1 + DBFile2 - WhiteSpace.

    As you can see, the whitespace value is actually retrieved from another host, so is that maybe the problem? Or can I not have three items in a trigger expression?

    I can get it to work this way:
    ((DBFile1 + DBFile2)>16000000000)&(Whitespace<100)

    But this isn't ideal... I'd rather track the actual size.

    Any thoughts?
  • kurt
    Junior Member
    • Aug 2005
    • 21

    #2
    This is My Expression to monitor exchange store size(priv1.edb&amp;priv1.stm)

    {HOST1:filesize[e:\\Program Files\\Exchsrvr\\mdbdata\\priv1.edb].last(0G)}+{HOST1:filesize[e:\\Program Files\\Exchsrvr\\mdbdata\\priv1.stm].last(0G)}>16000G

    Its works like a charm

    Comment

    • Nate Bell
      Senior Member
      • Feb 2005
      • 141

      #3
      Just taking a stab here, but maybe you need to specify the order of operations:

      ((({HOST1:filesize[C:\fileone.dat].last(0)}+{HOST1:filesize[C:\filetwo.dat].last(0)})-{HOST2:syslog[exchws].last(0)})>16000000000)

      Nate

      Comment

      • innomedia
        Junior Member
        • Jul 2005
        • 4

        #4
        If it's anything like what I've encountered in the past, the culprit is the minus sign. I solved that problem by bypassing the expression validity check in triggers.php.

        Comment

        Working...