Ad Widget

Collapse

Dashboard last 20 issues and trigger state

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • windsurf51
    Junior Member
    • Sep 2009
    • 20

    #1

    Dashboard last 20 issues and trigger state

    Hey

    I have a problem with refresh of dashboard ,

    if status does not change (problem is still there) , information of item can be different , but dashboard does not refresh this new value instead of triggers view ( i use {ITEM.VALUE} in trigger name)

    Is there any patch or trick to allow dashboard to display last value of item/trigger?

    Thx
    Last edited by windsurf51; 13-11-2009, 12:37.
  • windsurf51
    Junior Member
    • Sep 2009
    • 20

    #2
    Ok now i 'm now using ITEM.LASTVALUE for my triggers but because of that , events are showing last value too

    => i can't know previous value of trigger during first event


    is there any option to display :

    -triggers with ITEM.LASTVALUE ? (actual value)
    -events with ITEM.VALUE ? (value at problem time )
    Last edited by windsurf51; 05-11-2009, 18:39.

    Comment

    • richlv
      Senior Member
      Zabbix Certified Trainer
      Zabbix Certified SpecialistZabbix Certified Professional
      • Oct 2005
      • 3112

      #3
      well... you could try using both macros in the trigger name, maybe
      Zabbix 3.0 Network Monitoring book

      Comment

      • windsurf51
        Junior Member
        • Sep 2009
        • 20

        #4
        Yep !

        thats what i did

        i add {ITEM.LASTVALUE} ( {ITEM.VALUE} ) in trigger name

        Thx

        Comment

        • windsurf51
          Junior Member
          • Sep 2009
          • 20

          #5
          Well i found a trick to only display ITEM.LASTVALUE in dashboard and triggers , and have ITEM.VALUE on events parts


          -i add a new function in triggers.inc.php with a copy of expand_trigger_description_by_data function

          -then i modify ITEM.LASTVALUE part as if it was a ITEM.VALUE:

          if(zbx_strstr($description, '{ITEM.LASTVALUE}')){

          $value=($flag==ZBX_FLAG_TRIGGER)?
          trigger_get_func_value($row['expression'],ZBX_FLAG_TRIGGER,1,1):
          trigger_get_func_value($row['expression'],ZBX_FLAG_EVENT,1,$row['clock']);

          $description = str_replace('{ITEM.LASTVALUE}',
          $value,
          $description);
          }


          -then i used this function in events.php instead of normal function.


          Hope it will be useful for you too!

          Comment

          Working...