Ad Widget

Collapse

Abusing LLD with external checks

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • asrig
    Junior Member
    • Mar 2016
    • 2

    #1

    Abusing LLD with external checks

    I'd like some input on the "proper" way of doing this.

    I have a service I'm monitoring where it returns all statistics at once. It has counters, booleans, percentiles, pretty much the whole range of metric types. I've written an external check script that basically dumps all the metrics and metric values as key-value pairs for LLD to slurp up.

    Now I figured LLD would be great of this. I don't need to individually define the dozens and dozens of metrics, LLD will automatically create all of them. But the problem then comes in when I try to define triggers. A trigger prototype is mapped to item prototypes. And items prototypes are dead simple: just echo back the metric value from the external check as a "calculated" field. See attached pic.

    But I can't have the same trigger prototype for booleans, percentages, and counts.

    How can I separate the boolean metrics, percentage metrics, count metrics to get different triggers? What is the proper way to define multiple item prototypes for this? Filter metric type in my external script? Filter metric type in the LLD definition?
    I'm currently going all the way back and defining multiple discovery rules using dummy variables in my external check to get unique keys, item prototypes and filtering.

    This was done in Zabbix 2.2.2 on Ubuntu 14.04.
    Attached Files
Working...