440 lines
18 KiB
YAML
440 lines
18 KiB
YAML
zabbix_export:
|
|
version: '7.0'
|
|
template_groups:
|
|
- uuid: a571c0d144b14fd4a87a9d9b2aa9fcd6
|
|
name: Templates/Applications
|
|
host_groups:
|
|
- uuid: a571c0d144b14fd4a87a9d9b2aa9fcd6
|
|
name: Applications
|
|
templates:
|
|
- uuid: 24b64f6d22b446dabecc86ee3f199004
|
|
template: 'Control-M enterprise manager by HTTP'
|
|
name: 'Control-M enterprise manager by HTTP'
|
|
description: |
|
|
This template is designed to get metrics from the Control-M Enterprise Manager using the Control-M Automation API with HTTP agent.
|
|
|
|
This template monitors active Service Level Agreement (SLA) services, discovers Control-M servers using Low Level Discovery and also creates host prototypes for them in conjunction with the `Control-M server by HTTP` template.
|
|
|
|
To use this template, macros `{$API.TOKEN}` and `{$API.URI.ENDPOINT}` need to be set.
|
|
|
|
> See [Zabbix template operation](https://www.zabbix.com/documentation/7.0/manual/config/templates_out_of_the_box/http) for basic instructions.
|
|
|
|
Generated by official Zabbix template tool "Templator"
|
|
vendor:
|
|
name: Zabbix
|
|
version: 7.0-1
|
|
groups:
|
|
- name: Templates/Applications
|
|
items:
|
|
- uuid: 7d9ed576aeb045798b78414c89f3e597
|
|
name: 'Get Control-M servers'
|
|
type: HTTP_AGENT
|
|
key: controlm.servers
|
|
delay: 10m
|
|
history: '0'
|
|
value_type: TEXT
|
|
trends: '0'
|
|
description: 'Gets a list of servers.'
|
|
url: '{$API.URI.ENDPOINT}/config/servers'
|
|
headers:
|
|
- name: x-api-key
|
|
value: '{$API.TOKEN}'
|
|
tags:
|
|
- tag: component
|
|
value: raw
|
|
- uuid: 2bd2c27b8dc74656a00f6d2006399388
|
|
name: 'Get SLA services'
|
|
type: HTTP_AGENT
|
|
key: controlm.services
|
|
history: '0'
|
|
value_type: TEXT
|
|
trends: '0'
|
|
description: 'Gets all the SLA active services.'
|
|
url: '{$API.URI.ENDPOINT}/run/services/sla'
|
|
headers:
|
|
- name: x-api-key
|
|
value: '{$API.TOKEN}'
|
|
tags:
|
|
- tag: component
|
|
value: raw
|
|
discovery_rules:
|
|
- uuid: 388824178c264d51be116a693c2640de
|
|
name: 'Server discovery'
|
|
type: DEPENDENT
|
|
key: controlm.server.discovery
|
|
delay: '0'
|
|
description: 'Discovers the Control-M servers.'
|
|
host_prototypes:
|
|
- uuid: 1ade45fcbb9e407ca32542564b12f2b1
|
|
host: '{#SERVER.NAME}'
|
|
name: 'Control-M server [{#SERVER.NAME}]'
|
|
group_links:
|
|
- group:
|
|
name: Applications
|
|
group_prototypes:
|
|
- name: 'Control-M/{#SERVER.NAME}'
|
|
templates:
|
|
- name: 'Control-M server by HTTP'
|
|
macros:
|
|
- macro: '{$SERVER.NAME}'
|
|
value: '{#SERVER.NAME}'
|
|
master_item:
|
|
key: controlm.servers
|
|
lld_macro_paths:
|
|
- lld_macro: '{#SERVER.NAME}'
|
|
path: $.name
|
|
preprocessing:
|
|
- type: DISCARD_UNCHANGED_HEARTBEAT
|
|
parameters:
|
|
- 2h
|
|
- uuid: 567e5e0553c84ce2a9200d14dfc76593
|
|
name: 'SLA services discovery'
|
|
type: DEPENDENT
|
|
key: controlm.services.discovery
|
|
delay: '0'
|
|
lifetime: 1d
|
|
description: 'Discovers the SLA services in the Control-M environment.'
|
|
item_prototypes:
|
|
- uuid: 9daecffe0dfd402fb7300d484c2e9b80
|
|
name: 'Service [{#SERVICE.NAME}, {#SERVICE.JOB}]: jobs ''completed'''
|
|
type: DEPENDENT
|
|
key: 'service.jobs.status[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'',completed]'
|
|
delay: '0'
|
|
description: 'Gets the number of jobs in the state - `completed`.'
|
|
preprocessing:
|
|
- type: JSONPATH
|
|
parameters:
|
|
- $.statusByJobs.completed
|
|
- type: DISCARD_UNCHANGED_HEARTBEAT
|
|
parameters:
|
|
- 1h
|
|
master_item:
|
|
key: 'service.stats[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'']'
|
|
tags:
|
|
- tag: component
|
|
value: service
|
|
- tag: service-metric
|
|
value: jobs-completed
|
|
- tag: service-metric
|
|
value: jobs-stats
|
|
- tag: service-name
|
|
value: '{#SERVICE.NAME}'
|
|
- uuid: 27821e573ead422b830b4f9dba5c840f
|
|
name: 'Service [{#SERVICE.NAME}, {#SERVICE.JOB}]: jobs ''error'''
|
|
type: DEPENDENT
|
|
key: 'service.jobs.status[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'',error]'
|
|
delay: '0'
|
|
description: 'Gets the number of jobs in the state - `error`.'
|
|
preprocessing:
|
|
- type: JSONPATH
|
|
parameters:
|
|
- $.statusByJobs.error
|
|
- type: DISCARD_UNCHANGED_HEARTBEAT
|
|
parameters:
|
|
- 1h
|
|
master_item:
|
|
key: 'service.stats[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'']'
|
|
tags:
|
|
- tag: component
|
|
value: service
|
|
- tag: service-metric
|
|
value: jobs-error
|
|
- tag: service-metric
|
|
value: jobs-stats
|
|
- tag: service-name
|
|
value: '{#SERVICE.NAME}'
|
|
trigger_prototypes:
|
|
- uuid: c66f281b78e64c1c9c96ade1450eadbb
|
|
expression: 'last(/Control-M enterprise manager by HTTP/service.jobs.status[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'',error],#1)>0'
|
|
name: 'Control-M: Service [{#SERVICE.NAME}, {#SERVICE.JOB}]: jobs in ''error'' state'
|
|
opdata: 'Trigger value ''{ITEM.VALUE}'', Current value ''{ITEM.LASTVALUE}'''
|
|
priority: AVERAGE
|
|
description: 'There are services present which are in the state - `error`.'
|
|
tags:
|
|
- tag: scope
|
|
value: availability
|
|
- uuid: fe58d60475bd49f2a4e3f0bfc5ae020f
|
|
name: 'Service [{#SERVICE.NAME}, {#SERVICE.JOB}]: jobs ''executed'''
|
|
type: DEPENDENT
|
|
key: 'service.jobs.status[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'',executed]'
|
|
delay: '0'
|
|
description: 'Gets the number of jobs in the state - `executed`.'
|
|
preprocessing:
|
|
- type: JSONPATH
|
|
parameters:
|
|
- $.statusByJobs.executed
|
|
- type: DISCARD_UNCHANGED_HEARTBEAT
|
|
parameters:
|
|
- 1h
|
|
master_item:
|
|
key: 'service.stats[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'']'
|
|
tags:
|
|
- tag: component
|
|
value: service
|
|
- tag: service-metric
|
|
value: jobs-executed
|
|
- tag: service-metric
|
|
value: jobs-stats
|
|
- tag: service-name
|
|
value: '{#SERVICE.NAME}'
|
|
- uuid: 2843e6ba50584b27a66165f0accc5ed5
|
|
name: 'Service [{#SERVICE.NAME}, {#SERVICE.JOB}]: jobs ''waitCondition'''
|
|
type: DEPENDENT
|
|
key: 'service.jobs.status[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'',waitCondition]'
|
|
delay: '0'
|
|
description: 'Gets the number of jobs in the state - `waitCondition`.'
|
|
preprocessing:
|
|
- type: JSONPATH
|
|
parameters:
|
|
- $.statusByJobs.waitCondition
|
|
- type: DISCARD_UNCHANGED_HEARTBEAT
|
|
parameters:
|
|
- 1h
|
|
master_item:
|
|
key: 'service.stats[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'']'
|
|
tags:
|
|
- tag: component
|
|
value: service
|
|
- tag: service-metric
|
|
value: jobs-stats
|
|
- tag: service-metric
|
|
value: jobs-wait_condition
|
|
- tag: service-name
|
|
value: '{#SERVICE.NAME}'
|
|
- uuid: 409961fd6fed4f208340dfdb978a2430
|
|
name: 'Service [{#SERVICE.NAME}, {#SERVICE.JOB}]: jobs ''waitHost'''
|
|
type: DEPENDENT
|
|
key: 'service.jobs.status[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'',waitHost]'
|
|
delay: '0'
|
|
description: 'Gets the number of jobs in the state - `waitHost`.'
|
|
preprocessing:
|
|
- type: JSONPATH
|
|
parameters:
|
|
- $.statusByJobs.waitHost
|
|
- type: DISCARD_UNCHANGED_HEARTBEAT
|
|
parameters:
|
|
- 1h
|
|
master_item:
|
|
key: 'service.stats[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'']'
|
|
tags:
|
|
- tag: component
|
|
value: service
|
|
- tag: service-metric
|
|
value: jobs-stats
|
|
- tag: service-metric
|
|
value: jobs-wait_host
|
|
- tag: service-name
|
|
value: '{#SERVICE.NAME}'
|
|
- uuid: 6ae1bd92bd39446fbbea847088cd37e7
|
|
name: 'Service [{#SERVICE.NAME}, {#SERVICE.JOB}]: jobs ''waitResource'''
|
|
type: DEPENDENT
|
|
key: 'service.jobs.status[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'',waitResource]'
|
|
delay: '0'
|
|
description: 'Gets the number of jobs in the state - `waitResource`.'
|
|
preprocessing:
|
|
- type: JSONPATH
|
|
parameters:
|
|
- $.statusByJobs.waitResource
|
|
- type: DISCARD_UNCHANGED_HEARTBEAT
|
|
parameters:
|
|
- 1h
|
|
master_item:
|
|
key: 'service.stats[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'']'
|
|
tags:
|
|
- tag: component
|
|
value: service
|
|
- tag: service-metric
|
|
value: jobs-stats
|
|
- tag: service-metric
|
|
value: jobs-wait-resource
|
|
- tag: service-name
|
|
value: '{#SERVICE.NAME}'
|
|
- uuid: 0299415dfbca4ba6881a890bb9e9658c
|
|
name: 'Service [{#SERVICE.NAME}, {#SERVICE.JOB}]: jobs ''waitWorkload'''
|
|
type: DEPENDENT
|
|
key: 'service.jobs.status[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'',waitWorkload]'
|
|
delay: '0'
|
|
description: 'Gets the number of jobs in the state - `waitWorkload`.'
|
|
preprocessing:
|
|
- type: JSONPATH
|
|
parameters:
|
|
- $.statusByJobs.waitWorkload
|
|
- type: DISCARD_UNCHANGED_HEARTBEAT
|
|
parameters:
|
|
- 1h
|
|
master_item:
|
|
key: 'service.stats[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'']'
|
|
tags:
|
|
- tag: component
|
|
value: service
|
|
- tag: service-metric
|
|
value: jobs-stats
|
|
- tag: service-metric
|
|
value: jobs-wait_workload
|
|
- tag: service-name
|
|
value: '{#SERVICE.NAME}'
|
|
- uuid: 72516fca80024f9884efb7dd652f957e
|
|
name: 'Service [{#SERVICE.NAME}, {#SERVICE.JOB}]: stats'
|
|
type: DEPENDENT
|
|
key: 'service.stats[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'']'
|
|
delay: '0'
|
|
history: '0'
|
|
value_type: TEXT
|
|
trends: '0'
|
|
description: 'Gets the service statistics.'
|
|
preprocessing:
|
|
- type: JSONPATH
|
|
parameters:
|
|
- '$.activeServices.[?(@.serviceName == ''{#SERVICE.NAME}'')]'
|
|
error_handler: DISCARD_VALUE
|
|
- type: JSONPATH
|
|
parameters:
|
|
- '$.[?(@.serviceJob == ''{#SERVICE.JOB}'')].first()'
|
|
error_handler: DISCARD_VALUE
|
|
master_item:
|
|
key: controlm.services
|
|
tags:
|
|
- tag: component
|
|
value: raw
|
|
- uuid: a3f556bfb8d04a70b0c7407cdc458703
|
|
name: 'Service [{#SERVICE.NAME}, {#SERVICE.JOB}]: status'
|
|
type: DEPENDENT
|
|
key: 'service.status[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'']'
|
|
delay: '0'
|
|
description: 'Gets the service status.'
|
|
valuemap:
|
|
name: 'Control-M service status'
|
|
preprocessing:
|
|
- type: JSONPATH
|
|
parameters:
|
|
- $.status
|
|
- type: JAVASCRIPT
|
|
parameters:
|
|
- |
|
|
const idx = [
|
|
'Not Ok',
|
|
'Ok',
|
|
'Completed Ok',
|
|
'Ended Late'
|
|
].indexOf(value);
|
|
return idx !== -1 ? idx : 10;
|
|
- type: DISCARD_UNCHANGED_HEARTBEAT
|
|
parameters:
|
|
- 1h
|
|
master_item:
|
|
key: 'service.stats[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'']'
|
|
tags:
|
|
- tag: component
|
|
value: service
|
|
- tag: service-metric
|
|
value: status
|
|
- tag: service-name
|
|
value: '{#SERVICE.NAME}'
|
|
trigger_prototypes:
|
|
- uuid: e032410a5384441989538ff6781ef848
|
|
expression: |
|
|
last(/Control-M enterprise manager by HTTP/service.status['{#SERVICE.NAME}','{#SERVICE.JOB}'],#1)=0 or
|
|
last(/Control-M enterprise manager by HTTP/service.status['{#SERVICE.NAME}','{#SERVICE.JOB}'],#1)=10
|
|
name: 'Control-M: Service [{#SERVICE.NAME}, {#SERVICE.JOB}]: status [{ITEM.VALUE}]'
|
|
priority: AVERAGE
|
|
description: 'The service has encountered an issue.'
|
|
manual_close: 'YES'
|
|
tags:
|
|
- tag: scope
|
|
value: availability
|
|
- uuid: f64b017b0cf9456eb0afdf908cf2258e
|
|
expression: 'last(/Control-M enterprise manager by HTTP/service.status[''{#SERVICE.NAME}'',''{#SERVICE.JOB}''],#1)=3'
|
|
name: 'Control-M: Service [{#SERVICE.NAME}, {#SERVICE.JOB}]: status [{ITEM.VALUE}]'
|
|
priority: WARNING
|
|
description: 'The service has finished its job late.'
|
|
manual_close: 'YES'
|
|
tags:
|
|
- tag: scope
|
|
value: availability
|
|
graph_prototypes:
|
|
- uuid: 53190fc52e094018926ca5351198aace
|
|
name: 'Service [{#SERVICE.NAME}, {#SERVICE.JOB}]: jobs statuses'
|
|
graph_items:
|
|
- drawtype: DASHED_LINE
|
|
color: 29235c
|
|
item:
|
|
host: 'Control-M enterprise manager by HTTP'
|
|
key: 'service.jobs.status[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'',executed]'
|
|
- sortorder: '1'
|
|
drawtype: DASHED_LINE
|
|
color: 7e286e
|
|
item:
|
|
host: 'Control-M enterprise manager by HTTP'
|
|
key: 'service.jobs.status[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'',waitCondition]'
|
|
- sortorder: '2'
|
|
drawtype: DASHED_LINE
|
|
color: c73464
|
|
item:
|
|
host: 'Control-M enterprise manager by HTTP'
|
|
key: 'service.jobs.status[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'',waitResource]'
|
|
- sortorder: '3'
|
|
drawtype: DASHED_LINE
|
|
color: f66343
|
|
item:
|
|
host: 'Control-M enterprise manager by HTTP'
|
|
key: 'service.jobs.status[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'',waitHost]'
|
|
- sortorder: '4'
|
|
drawtype: DASHED_LINE
|
|
color: ffa600
|
|
item:
|
|
host: 'Control-M enterprise manager by HTTP'
|
|
key: 'service.jobs.status[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'',waitWorkload]'
|
|
- sortorder: '5'
|
|
color: 00FF00
|
|
yaxisside: RIGHT
|
|
item:
|
|
host: 'Control-M enterprise manager by HTTP'
|
|
key: 'service.jobs.status[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'',completed]'
|
|
- sortorder: '6'
|
|
color: FF0000
|
|
item:
|
|
host: 'Control-M enterprise manager by HTTP'
|
|
key: 'service.jobs.status[''{#SERVICE.NAME}'',''{#SERVICE.JOB}'',error]'
|
|
master_item:
|
|
key: controlm.services
|
|
lld_macro_paths:
|
|
- lld_macro: '{#SERVICE.JOB}'
|
|
path: $.serviceJob
|
|
- lld_macro: '{#SERVICE.NAME}'
|
|
path: $.serviceName
|
|
preprocessing:
|
|
- type: JSONPATH
|
|
parameters:
|
|
- $.activeServices
|
|
error_handler: CUSTOM_VALUE
|
|
error_handler_params: '[]'
|
|
- type: DISCARD_UNCHANGED_HEARTBEAT
|
|
parameters:
|
|
- 1h
|
|
tags:
|
|
- tag: class
|
|
value: software
|
|
- tag: target
|
|
value: controlm
|
|
macros:
|
|
- macro: '{$API.TOKEN}'
|
|
type: SECRET_TEXT
|
|
description: 'A token to use for API connections.'
|
|
- macro: '{$API.URI.ENDPOINT}'
|
|
value: '<set the api uri endpoint here>'
|
|
description: 'The API endpoint is a URI - for example, `https://monitored.controlm.instance:8443/automation-api`.'
|
|
valuemaps:
|
|
- uuid: 54213ae65be64878988c9145d8ae86e4
|
|
name: 'Control-M service status'
|
|
mappings:
|
|
- value: '0'
|
|
newvalue: 'Not Ok'
|
|
- value: '1'
|
|
newvalue: Ok
|
|
- value: '2'
|
|
newvalue: 'Completed Ok'
|
|
- value: '3'
|
|
newvalue: 'Ended Late'
|
|
- value: '10'
|
|
newvalue: Unknown
|