9 Discovery of Windows performance counter instances

Overview

It is possible to discover object instances of Windows performance counters. This is useful for multi-instance performance counters.

Item key

The item to use in the discovery rule is

  1. perf_instance.discovery[object]

or, to be able to provide the object name in English only, independently of OS localization:

  1. perf_instance_en.discovery[object]

For example:

  1. perf_instance.discovery[Processador]
  2. perf_instance_en.discovery[Processor]

These items are supported since Zabbix Windows agent 5.0.1.

Supported macros

The discovery will return all instances of the specified object in the {#INSTANCE} macro, which may be used in the prototypes of perf_count and perf_count_en items.

  1. [
  2. {"{#INSTANCE}":"0"},
  3. {"{#INSTANCE}":"1"},
  4. {"{#INSTANCE}":"_Total"}
  5. ]

For example, if the item key used in the discovery rule is:

  1. perf_instance.discovery[Processor]

you may create an item prototype:

  1. perf_counter["\Processor({#INSTANCE})\% Processor Time"]

Notes:

  • If the specified object is not found or does not support variable instances then the discovery item will become NOTSUPPORTED.

  • If the specified object supports variable instances, but currently does not have any instances, then an empty JSON array will be returned.

  • In case of duplicate instances they will be skipped.