3

I use zabbix 2.4 and Template Linux OS. How to configure different values of for the same trigger on different hosts. When I click on the name of a trigger and edit it, the value is being changed on all hosts connected to that template?

enter image description here

Edik Mkoyan
  • 405
  • 1
  • 5
  • 24
  • Which part of the trigger would you like to make host-specific? Could you please give an example? – asaveljevs Dec 21 '15 at 14:44
  • Meanwhile, only trigger name and expression cannot be overridden on the host level. Other settings like description, URL, severity can be changed (until the next trigger update in the template overwrites those values specifically). – asaveljevs Dec 21 '15 at 14:46
  • I want to change numeric values in the expression for this specific host, but as you can see in the image, it is grey and not editable. – Edik Mkoyan Dec 21 '15 at 15:47

2 Answers2

8

The usual approach in this case is to use user macros. Instead of hardcoding "30" in the trigger expression, we instead replace it with a user macro:

{Template OS Linux:system.cpu.util[,iowait].avg(10m)} > {$MAX_IOWAIT}

We then define {$MAX_IOWAIT} to be "30" on Template OS Linux and then we can override the value of that macro on each host.

asaveljevs
  • 281
  • 1
  • 5
2

You may clone existing trigger as new and edit it on host-basis. Otherwise all hosts in the template will be affected.

Vladimir
  • 81
  • 3