User macros

The macros we used before are built-in. Zabbix also allows users to define macros and use them later. In this case, it might be even more important to call them variables instead, so consider using that term too. Let's start with a practical application of a user macro and discuss the details a bit later.

Go to Configuration | Templates and click on C_Template_Linux in the Templates column. Switch to the Macros tab and add one new macro:

  • Macro: {$CPU_LOAD_THRESHOLD}
  • Value: 1

When done, click on Update. We have defined one macro on the template, but it is not used at this time. Click on Triggers next to C_Template_Linux, then ...

Get Zabbix 4 Network Monitoring - Third Edition now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.