Zabbix Documentation 2.4

2.23.04.04.2 (current)In development:4.4 (devel)Unsupported:1.82.02.43.23.4

User Tools

Site Tools


Sidebar

manual:config:templates:template

1 Configuring a template

Overview

Configuring a template requires that you first create a template by defining its general parameters and then you add entities (items, triggers, graphs etc.) to it.

Creating a template

To create a template, do the following:

  • Go to Configuration → Templates
  • Click on Create template
  • Edit template attributes

The Template tab contains general template attributes.

Template attributes:

ParameterDescription
Template name Unique template name.
Visible name If you set this name, it will be the one visible in lists, maps, etc.
Groups Host/template groups the template belongs to.
New group A new group can be created to hold the template.
Ignored, if empty.
Hosts/Templates List of hosts/templates the template is applied to.
Description Enter the template description.

The Linked templates tab allows you to link one or more “nested” templates to this template. All entities (items, triggers, graphs etc.) will be inherited from the linked templates.

To link a new template, start typing in the Link new templates field until a list of templates corresponding to the entered letter(s) appear. Scroll down to select. When all templates to be linked are selected, click on Add.

To unlink a template, use one of the two options in the Linked templates block:

  • Unlink - unlink the template, but preserve its items, triggers and graphs
  • Unlink and clear - unlink the template and remove all its items, triggers and graphs

The Macros tab allows you to define template-level user macros.

Buttons:

Add the template. The added template should appear in the list.
Update the properties of an existing template.
Create another template based on the properties of the current template, including the entities (items, triggers, etc) inherited from linked templates.
Create another template based on the properties of the current template, including the entities (items, triggers, etc) both inherited from linked templates and directly attached to the current template.
Delete the template; entities of the template (items, triggers, etc) remain with the linked hosts.
Delete the template and all its entities from linked hosts.
Cancel the editing of template properties.

With a template created, it is time to add some entities to it.

Items have to be added to a template first. Triggers and graphs cannot be added without the corresponding item.

Adding items, triggers, graphs

To add items to the template, do the following:

  • Go to Configuration → Hosts (or Templates)
  • Click on Items in the row of the required host/template
  • Mark the checkboxes of items you want add to the template
  • Select Copy selected to… below the item list and click on Go
  • Select the template (or group of templates) the items should be copied to and click on Copy

All the selected items should be copied to the template.

Adding triggers and graphs is done in similar fashion (from the list of triggers and graphs respectively), again, keeping in mind that they can only be added if the required items are added first.

Adding screens

To add screens to a template in Configuration → Templates, do the following:

  • Click on Screens in the row of the template
  • Configure a screen following the usual method of configuring screens
The elements that can be included in a template screen are: simple graph, custom graph, clock, plain text, URL.

Configuring low-level discovery rules

See the low-level discovery section of the manual.

Adding web scenarios

To add web scenarios to a template in Configuration → Templates, do the following: