Ad Widget

Collapse

editing trigger expressions that are linked to template ?

Collapse
This topic has been answered.
X
X
 
  • Time
  • Show
Clear All
new posts
  • jajest
    Junior Member
    • Mar 2022
    • 4

    #1

    editing trigger expressions that are linked to template ?

    Hi,

    My problem is that I hace several hosts that do a reboot every night. Every server has a different hour to reboot. They do not reboot all at the same time.
    My hosts which are configured with a linked template. Therefore I guess the trigger expressions are not editable.
    When I unlink the template, I can edit the expression and add for example a time so that the trigger will not go off during reboot.
    Example: max(/TS1 - 111/icmpping,#3)=0 and (time()<231500 or time()>234500)

    this part: and (time()<231500 or time()>234500 will prevent the trigger from firing between 23h15 and 23h45

    To be able to edit this expression with the "and (time()<231500 or time()>234500" I have to unlink the template.

    But ... I would prefer that my hosts stays linked with the template ... is there a way to prevent the trigger from firing during a time span while the host is linked to a template ?

    Marc



  • Answer selected by jajest at 14-03-2022, 14:45.
    cyber
    Senior Member
    Zabbix Certified SpecialistZabbix Certified Professional
    • Dec 2006
    • 4807

    Replace those hardcoded times with macros ({$BOOT_START}, {$BOOT_STOP} for example). Values to those macros set on host level. This way you have same template everywhere, but values to macros are taken "locally", from host.

    Comment


    • jajest
      jajest commented
      Editing a comment
      Thanks a lot ! this is exactly what I need
  • cyber
    Senior Member
    Zabbix Certified SpecialistZabbix Certified Professional
    • Dec 2006
    • 4807

    #2
    Replace those hardcoded times with macros ({$BOOT_START}, {$BOOT_STOP} for example). Values to those macros set on host level. This way you have same template everywhere, but values to macros are taken "locally", from host.

    Comment


    • jajest
      jajest commented
      Editing a comment
      Thanks a lot ! this is exactly what I need
Working...