Setting up different kinds of macros
When we are working with templates, a very efficient way to make your templates more useful is through the use of macros. In this recipe, we’ll discover how to use macros to do this.
Getting ready
We are going to need our Zabbix server and our SNMP-monitored host from the previous recipes. We’ll also need our Zabbix template, as created in the previous recipe.
How to do it…
Now, let’s start with creating some macros on a template level. We’ll be making two different types of macros.
Defining a user macro
- First, we’ll define a user macro on our template. Navigate to Data collection | Templates and click on our Custom Linux by SNMP template.
- Here, we will go to Macros and fill in the following fields:
Figure 5.18 – Template-level macros
- Click on Update, and let’s move to Trigger to define a new trigger:
...