HashiCorp Consul

Consul is a service networking solution to automate network configurations, discover services, and enable secure connectivity across any cloud or runtime.

Available solutions

Zabbix version 8.0 7.4 7.2 7.0 6.4 6.2 6.0
Download

HashiCorp Consul Node by HTTP

Overview

The template to monitor HashiCorp Consul by Zabbix that works without any external scripts.
Most of the metrics are collected in one go, thanks to Zabbix bulk data collection.
Do not forget to enable Prometheus format for export metrics. See documentation.
More information about metrics you can find in official documentation.

Template HashiCorp Consul Node by HTTP — collects metrics by HTTP agent from /v1/agent/metrics endpoint.

Requirements

Zabbix version: 8.0 and higher.

Tested versions

This template has been tested on:

  • HashiCorp Consul 2.0.4

Configuration

Zabbix should be configured according to the instructions in the Templates out of the box section.

Setup

Internal service metrics are collected from /v1/agent/metrics endpoint. Do not forget to enable Prometheus format for export metrics. See documentation. Template need to use Authorization via API token.

Don't forget to change macros {$CONSUL.NODE.API.URL}, {$CONSUL.TOKEN}.
Also, see the Macros section for a list of macros used to set trigger values. More information about metrics you can find in official documentation.

This template support Consul namespaces. You can set macros {$CONSUL.LLD.FILTER.SERVICE_NAMESPACE.MATCHES}, {$CONSUL.LLD.FILTER.SERVICE_NAMESPACE.NOT_MATCHES} if you want to filter discovered services by namespace.
In case of Open Source version service namespace will be set to 'None'.

NOTE. Some metrics may not be collected depending on your HashiCorp Consul instance version and configuration.
NOTE. You maybe are interested in Envoy Proxy by HTTP template.

Macros used

Name Description Default
{$HTTP.TLS.VERIFY}

TLS certificate verification for the script item: "none" - disabled, "peer" - verify the certificate chain and expiration, "full" - full verification. Any other value enables full verification. To override the setting for this template only, define the macro with the context "HashiCorp Consul Node", e.g. {$HTTP.TLS.VERIFY:"HashiCorp Consul Node"}.

full
{$CONSUL.NODE.API.URL}

Consul instance URL.

http://localhost:8500
{$CONSUL.TOKEN}

Consul auth token.

{$CONSUL.OPEN.FDS.MAX.WARN}

Maximum percentage of used file descriptors.

90
{$CONSUL.TLS.CERT.EXPIRY.MIN}

Minimum acceptable time before TLS certificate expiry for the trigger expression.

7d
{$CONSUL.LEAF.CERT.EXPIRY.MIN}

Minimum acceptable time before Connect leaf certificate expiry for the trigger expression. Leaf certs typically rotate much more often than the agent TLS cert (hours, not days).

6h
{$CONSUL.MESH.ROOT_CA.EXPIRY.MIN}

Minimum acceptable time before service mesh root CA certificate expiry for the trigger expression. Root CA rotation is a rare, planned operation — keep this threshold generous.

30d
{$CONSUL.MESH.SIGNING_CA.EXPIRY.MIN}

Minimum acceptable time before service mesh signing CA certificate expiry for the trigger expression.

30d
{$CONSUL.LICENSE.EXPIRY.MIN}

Minimum acceptable time before Consul Enterprise license expiry for the trigger expression. Enterprise only.

30d
{$CONSUL.LLD.FILTER.LOCAL_SERVICE_NAME.MATCHES}

Filter of discoverable discovered services on local node.

.*
{$CONSUL.LLD.FILTER.LOCAL_SERVICE_NAME.NOT_MATCHES}

Filter to exclude discovered services on local node.

CHANGE IF NEEDED
{$CONSUL.LLD.FILTER.SERVICE_NAMESPACE.MATCHES}

Filter of discoverable discovered service by namespace on local node. Enterprise only, in case of Open Source version Namespace will be set to 'None'.

.*
{$CONSUL.LLD.FILTER.SERVICE_NAMESPACE.NOT_MATCHES}

Filter to exclude discovered service by namespace on local node. Enterprise only, in case of Open Source version Namespace will be set to 'None'.

CHANGE IF NEEDED

Items

Name Description Type Key and additional info
Get instance metrics

Get raw metrics from Consul instance /metrics endpoint.

HTTP agent consul.get_metrics

Preprocessing

  • Check for not supported value: any error

    ⛔️Custom on fail: Discard value

Get node info

Get configuration and member information of the local agent.

HTTP agent consul.get_node_info

Preprocessing

  • Check for not supported value: any error

    ⛔️Custom on fail: Discard value

Role

Role of current Consul agent.

Dependent item consul.role

Preprocessing

  • JSON Path: $.Config.Server

  • Boolean to decimal
  • Discard unchanged with heartbeat: 3h

Version

Version of Consul agent.

Dependent item consul.version

Preprocessing

  • JSON Path: $.Config.Version

  • Discard unchanged with heartbeat: 3h

Number of services

Number of services on current node.

Dependent item consul.services_number

Preprocessing

  • JSON Path: $.Stats.agent.services

  • Discard unchanged with heartbeat: 3h

Number of checks

Number of checks on current node.

Dependent item consul.checks_number

Preprocessing

  • JSON Path: $.Stats.agent.checks

  • Discard unchanged with heartbeat: 3h

Number of check monitors

Number of check monitors on current node.

Dependent item consul.check_monitors_number

Preprocessing

  • JSON Path: $.Stats.agent.check_monitors

  • Discard unchanged with heartbeat: 3h

Process CPU seconds, total

Total user and system CPU time spent in seconds.

Dependent item consul.cpu_seconds_total.rate

Preprocessing

  • Prometheus pattern: VALUE(process_cpu_seconds_total)

    ⛔️Custom on fail: Discard value

  • Change per second
Virtual memory size

Virtual memory size in bytes.

Dependent item consul.virtual_memory_bytes

Preprocessing

  • Prometheus pattern: VALUE(process_virtual_memory_bytes)

RSS memory usage

Resident memory size in bytes.

Dependent item consul.resident_memory_bytes

Preprocessing

  • Prometheus pattern: VALUE(process_resident_memory_bytes)

Goroutine count

The number of Goroutines on Consul instance.

Dependent item consul.goroutines

Preprocessing

  • Prometheus pattern: VALUE(go_goroutines)

Open file descriptors

Number of open file descriptors.

Dependent item consul.process_open_fds

Preprocessing

  • Prometheus pattern: VALUE(process_open_fds)

Open file descriptors, max

Maximum number of open file descriptors.

Dependent item consul.process_max_fds

Preprocessing

  • Prometheus pattern: VALUE(process_max_fds)

Client RPC, per second

Number of times per second whenever a Consul agent in client mode makes an RPC request to a Consul server.

This gives a measure of how much a given agent is loading the Consul servers.

This is only generated by agents in client mode, not Consul servers.

Dependent item consul.client_rpc

Preprocessing

  • Prometheus pattern: VALUE(consul_client_rpc)

    ⛔️Custom on fail: Discard value

  • Change per second
Client RPC failed, per second

Number of times per second whenever a Consul agent in client mode makes an RPC request to a Consul server and fails.

Dependent item consul.client_rpc_failed

Preprocessing

  • Prometheus pattern: VALUE(consul_client_rpc_failed)

    ⛔️Custom on fail: Discard value

  • Change per second
Client RPC exceeded, per second

Number of times per second whenever a Consul agent makes an RPC request to a Consul server and gets rate limited by that agent's limits configuration.

Dependent item consul.client_rpc_exceeded

Preprocessing

  • Prometheus pattern: VALUE(consul_client_rpc_exceeded)

    ⛔️Custom on fail: Discard value

  • Change per second
RPC: Request errors, per second

Number of times per second a server returns an error from an RPC request.

Dependent item consul.rpc.request_error.rate

Preprocessing

  • Prometheus pattern: VALUE(consul_rpc_request_error)

    ⛔️Custom on fail: Discard value

  • Change per second
RPC: Rate limit exceeded, per second

Number of times per second an RPC is over a configured rate limit. Note: in permissive mode, the RPC will have still been allowed to proceed.

Dependent item consul.rpc.rate_limit_exceeded.rate

Preprocessing

  • Prometheus pattern: VALUE(consul_rpc_rate_limit_exceeded)

    ⛔️Custom on fail: Discard value

  • Change per second
TCP connections, accepted per second

This metric counts the number of times a Consul agent has accepted an incoming TCP stream connection per second.

Dependent item consul.memberlist.tcp_accept

Preprocessing

  • Prometheus pattern: VALUE(consul_memberlist_tcp_accept)

    ⛔️Custom on fail: Discard value

  • Change per second
TCP connections, per second

This metric counts the number of times a Consul agent has initiated a push/pull sync with an other agent per second.

Dependent item consul.memberlist.tcp_connect

Preprocessing

  • Prometheus pattern: VALUE(consul_memberlist_tcp_connect)

    ⛔️Custom on fail: Discard value

  • Change per second
TCP send bytes, per second

This metric measures the total number of bytes sent by a Consul agent through the TCP protocol per second.

Dependent item consul.memberlist.tcp_sent

Preprocessing

  • Prometheus pattern: VALUE(consul_memberlist_tcp_sent)

    ⛔️Custom on fail: Discard value

  • Change per second
UDP received bytes, per second

This metric measures the total number of bytes received by a Consul agent through the UDP protocol per second.

Dependent item consul.memberlist.udp_received

Preprocessing

  • Prometheus pattern: VALUE(consul_memberlist_udp_received)

    ⛔️Custom on fail: Discard value

  • Change per second
UDP sent bytes, per second

This metric measures the total number of bytes sent by a Consul agent through the UDP protocol per second.

Dependent item consul.memberlist.udp_sent

Preprocessing

  • Prometheus pattern: VALUE(consul_memberlist_udp_sent)

    ⛔️Custom on fail: Discard value

  • Change per second
GC pause, p90

The 90 percentile for the number of nanoseconds consumed by stop-the-world garbage collection (GC) pauses since Consul started, in milliseconds.

Dependent item consul.gc_pause.p90

Preprocessing

  • Prometheus pattern: VALUE(consul_runtime_gc_pause_ns{quantile="0.9"})

    ⛔️Custom on fail: Discard value

  • JavaScript: The text is too long. Please see the template.

  • Custom multiplier: 1.0E-9

GC pause, p50

The 50 percentile (median) for the number of nanoseconds consumed by stop-the-world garbage collection (GC) pauses since Consul started, in milliseconds.

Dependent item consul.gc_pause.p50

Preprocessing

  • Prometheus pattern: VALUE(consul_runtime_gc_pause_ns{quantile="0.5"})

    ⛔️Custom on fail: Discard value

  • JavaScript: The text is too long. Please see the template.

  • Custom multiplier: 1.0E-9

Memberlist: Gossip, p90

The 90 percentile for the number of gossips (messages) broadcasted to a set of randomly selected nodes.

Dependent item consul.memberlist.dispatch_log.p90

Preprocessing

  • Prometheus pattern: VALUE(consul_memberlist_gossip{quantile="0.9"})

    ⛔️Custom on fail: Discard value

  • JavaScript: The text is too long. Please see the template.

Memberlist: Gossip, p50

The 50 for the number of gossips (messages) broadcasted to a set of randomly selected nodes.

Dependent item consul.memberlist.gossip.p50

Preprocessing

  • Prometheus pattern: VALUE(consul_memberlist_gossip{quantile="0.5"})

    ⛔️Custom on fail: Discard value

  • JavaScript: The text is too long. Please see the template.

Memberlist: Probe node, p90

The 90 percentile for the time taken to perform a single round of failure detection on a select Consul agent.

Dependent item consul.memberlist.probe_node.p90

Preprocessing

  • Prometheus pattern: VALUE(consul_memberlist_probeNode{quantile="0.9"})

    ⛔️Custom on fail: Discard value

  • JavaScript: The text is too long. Please see the template.

Memberlist: Probe node, p50

The 50 percentile (median) for the time taken to perform a single round of failure detection on a select Consul agent.

Dependent item consul.memberlist.probe_node.p50

Preprocessing

  • Prometheus pattern: VALUE(consul_memberlist_probeNode{quantile="0.5"})

    ⛔️Custom on fail: Discard value

  • JavaScript: The text is too long. Please see the template.

Memberlist: Push pull node, p90

The 90 percentile for the number of Consul agents that have exchanged state with this agent.

Dependent item consul.memberlist.push_pull_node.p90

Preprocessing

  • Prometheus pattern: VALUE(consul_memberlist_pushPullNode{quantile="0.9"})

    ⛔️Custom on fail: Discard value

  • JavaScript: The text is too long. Please see the template.

Memberlist: Push pull node, p50

The 50 percentile (median) for the number of Consul agents that have exchanged state with this agent.

Dependent item consul.memberlist.push_pull_node.p50

Preprocessing

  • Prometheus pattern: VALUE(consul_memberlist_pushPullNode{quantile="0.5"})

    ⛔️Custom on fail: Discard value

  • JavaScript: The text is too long. Please see the template.

KV store: Apply, p90

The 90 percentile for the time it takes to complete an update to the KV store.

Dependent item consul.kvs.apply.p90

Preprocessing

  • Prometheus pattern: VALUE(consul_kvs_apply{quantile="0.9"})

    ⛔️Custom on fail: Discard value

  • JavaScript: The text is too long. Please see the template.

KV store: Apply, p50

The 50 percentile (median) for the time it takes to complete an update to the KV store.

Dependent item consul.kvs.apply.p50

Preprocessing

  • Prometheus pattern: VALUE(consul_kvs_apply{quantile="0.5"})

    ⛔️Custom on fail: Discard value

  • JavaScript: The text is too long. Please see the template.

KV store: Apply, rate

The number of updates to the KV store per second.

Dependent item consul.kvs.apply.rate

Preprocessing

  • Prometheus pattern: VALUE(consul_kvs_apply_count)

    ⛔️Custom on fail: Discard value

  • Change per second
ACL: Resolves, rate

The number of ACL resolves per second.

Dependent item consul.acl.resolves.rate

Preprocessing

  • Prometheus pattern: VALUE(consul_acl_ResolveToken_count)

    ⛔️Custom on fail: Discard value

  • Change per second
Catalog: Register, rate

The number of catalog register operation per second.

Dependent item consul.catalog.register.rate

Preprocessing

  • Prometheus pattern: VALUE(consul_catalog_register_count)

    ⛔️Custom on fail: Discard value

  • Change per second
Catalog: Deregister, rate

The number of catalog deregister operation per second.

Dependent item consul.catalog.deregister.rate

Preprocessing

  • Prometheus pattern: VALUE(consul_catalog_deregister_count)

    ⛔️Custom on fail: Discard value

  • Change per second
Cache: Entries count

Represents the number of entries in the agent's cache.

Dependent item consul.cache.entries_count

Preprocessing

  • Prometheus pattern: VALUE(consul_cache_entries_count)

    ⛔️Custom on fail: Discard value

Cache: Fetch errors, per second

Number of failed fetches by the cache per second.

Dependent item consul.cache.fetch_error.rate

Preprocessing

  • Prometheus pattern: VALUE(consul_cache_fetch_error)

    ⛔️Custom on fail: Discard value

  • Change per second
Cache: Bypass, per second

Number of times per second a request bypassed the cache because no cache-key was provided.

Dependent item consul.cache.bypass.rate

Preprocessing

  • Prometheus pattern: VALUE(consul_cache_bypass)

    ⛔️Custom on fail: Discard value

  • Change per second
TLS certificate expiry

Seconds until the agent TLS certificate expires. Updated every hour.

Dependent item consul.tls_cert_expiry

Preprocessing

  • Prometheus pattern: VALUE(consul_agent_tls_cert_expiry)

    ⛔️Custom on fail: Discard value

Leaf certificate expiry

Seconds until the soonest-expiring Connect leaf certificate across all registered services expires. Leaf certificates are short-lived and renewed automatically well before expiry.

Dependent item consul.leaf_cert_expiry

Preprocessing

  • Prometheus pattern: MIN(consul_leaf_certs_cert_expiry)

    ⛔️Custom on fail: Discard value

Leaf certificate renewal failures

Number of failures to renew the Connect leaf certificate.

Dependent item consul.leaf_cert_renewal_failure

Preprocessing

  • Prometheus pattern: SUM(consul_leaf_certs_cert_renewal_failure)

    ⛔️Custom on fail: Discard value

Mesh root CA expiry

Seconds until the service mesh root certificate expires. Updated every hour.

Dependent item consul.mesh_root_ca_expiry

Preprocessing

  • Prometheus pattern: VALUE(consul_mesh_active_root_ca_expiry)

    ⛔️Custom on fail: Discard value

  • Custom multiplier: 1

    ⛔️Custom on fail: Discard value

Mesh signing CA expiry

Seconds until the service mesh signing (intermediate) certificate expires. Updated every hour.

Dependent item consul.mesh_signing_ca_expiry

Preprocessing

  • Prometheus pattern: VALUE(consul_mesh_active_signing_ca_expiry)

    ⛔️Custom on fail: Discard value

  • Custom multiplier: 1

    ⛔️Custom on fail: Discard value

License expiry

Seconds until the Consul Enterprise license expires. Enterprise only.

Dependent item consul.license_expiry

Preprocessing

  • Prometheus pattern: VALUE(consul_system_licenseExpiration)

    ⛔️Custom on fail: Discard value

  • Custom multiplier: 3600

Get local services

Get all the services that are registered with the local agent and their status.

Script consul.get_local_services
Get local services check

Data collection check.

Dependent item consul.get_local_services.check

Preprocessing

  • JSON Path: $.error

    ⛔️Custom on fail: Set value to

  • Discard unchanged with heartbeat: 3h

Triggers

Name Description Expression Severity Dependencies and additional info
HashiCorp Consul Node: Version has been changed

Consul version has changed. Acknowledge to close the problem manually.

last(/HashiCorp Consul Node by HTTP/consul.version,#1)<>last(/HashiCorp Consul Node by HTTP/consul.version,#2) and length(last(/HashiCorp Consul Node by HTTP/consul.version))>0 Info Manual close: Yes
HashiCorp Consul Node: Current number of open files is too high

"Heavy file descriptor usage (i.e., near the process’s file descriptor limit) indicates a potential file descriptor exhaustion issue."

min(/HashiCorp Consul Node by HTTP/consul.process_open_fds,5m)/last(/HashiCorp Consul Node by HTTP/consul.process_max_fds)*100>{$CONSUL.OPEN.FDS.MAX.WARN} Warning
HashiCorp Consul Node: TLS certificate expires soon

Agent's TLS certificate will expire soon. Renew it before expiration to avoid connectivity issues.

last(/HashiCorp Consul Node by HTTP/consul.tls_cert_expiry)>0 and last(/HashiCorp Consul Node by HTTP/consul.tls_cert_expiry)<{$CONSUL.TLS.CERT.EXPIRY.MIN} Warning
HashiCorp Consul Node: TLS certificate has already expired

Agent's TLS certificate has expired. Connectivity relying on this certificate is likely broken.

last(/HashiCorp Consul Node by HTTP/consul.tls_cert_expiry)<0 High
HashiCorp Consul Node: Leaf certificate expires soon

Connect leaf certificate will expire soon and has not been renewed in time. This may indicate a problem with automatic certificate renewal.

last(/HashiCorp Consul Node by HTTP/consul.leaf_cert_expiry)>0 and last(/HashiCorp Consul Node by HTTP/consul.leaf_cert_expiry)<{$CONSUL.LEAF.CERT.EXPIRY.MIN} Warning
HashiCorp Consul Node: Leaf certificate has already expired

Connect leaf certificate has expired. Services in the mesh relying on it have likely lost connectivity.

last(/HashiCorp Consul Node by HTTP/consul.leaf_cert_expiry)<0 High
HashiCorp Consul Node: Leaf certificate renewal failed

Connect leaf certificate renewal has failed. Services in the mesh may lose connectivity once the current certificate expires.

last(/HashiCorp Consul Node by HTTP/consul.leaf_cert_renewal_failure)>0 Warning
HashiCorp Consul Node: Mesh root CA expires soon

Service mesh root CA certificate will expire soon. Root CA rotation requires planning across the whole mesh — do not leave this until the last moment.

last(/HashiCorp Consul Node by HTTP/consul.mesh_root_ca_expiry)>0 and last(/HashiCorp Consul Node by HTTP/consul.mesh_root_ca_expiry)<{$CONSUL.MESH.ROOT_CA.EXPIRY.MIN} Warning
HashiCorp Consul Node: Mesh root CA has already expired

Service mesh root CA certificate has expired. This is likely causing a mesh-wide outage.

last(/HashiCorp Consul Node by HTTP/consul.mesh_root_ca_expiry)<0 High
HashiCorp Consul Node: Mesh signing CA expires soon

Service mesh signing CA certificate will expire soon.

last(/HashiCorp Consul Node by HTTP/consul.mesh_signing_ca_expiry)>0 and last(/HashiCorp Consul Node by HTTP/consul.mesh_signing_ca_expiry)<{$CONSUL.MESH.SIGNING_CA.EXPIRY.MIN} Warning
HashiCorp Consul Node: Mesh signing CA has already expired

Service mesh signing CA certificate has expired. This is likely causing a mesh-wide outage.

last(/HashiCorp Consul Node by HTTP/consul.mesh_signing_ca_expiry)<0 High
HashiCorp Consul Node: License expires soon

Consul Enterprise license will expire soon. Renew it to avoid Enterprise features being disabled.

last(/HashiCorp Consul Node by HTTP/consul.license_expiry)>0 and last(/HashiCorp Consul Node by HTTP/consul.license_expiry)<{$CONSUL.LICENSE.EXPIRY.MIN} Warning
HashiCorp Consul Node: License has already expired

Consul Enterprise license has expired.

last(/HashiCorp Consul Node by HTTP/consul.license_expiry)<0 High
HashiCorp Consul Node: Failed to get local services

Failed to get local services. Check debug log for more information.

length(last(/HashiCorp Consul Node by HTTP/consul.get_local_services.check))>0 Warning

LLD rule Local node services discovery

Name Description Type Key and additional info
Local node services discovery

Discover metrics for services that are registered with the local agent.

Dependent item consul.node_services_lld

Preprocessing

  • JavaScript: The text is too long. Please see the template.

  • Discard unchanged with heartbeat: 3h

Item prototypes for Local node services discovery

Name Description Type Key and additional info
["{#SERVICE_NAME}"]: Aggregated status

Aggregated values of all health checks for the service instance.

Dependent item consul.service.aggregated_state["{#SERVICE_ID}"]

Preprocessing

  • JSON Path: $[?(@.id == "{#SERVICE_ID}")].status.first()

  • JavaScript: The text is too long. Please see the template.

  • Discard unchanged with heartbeat: 3h

["{#SERVICE_NAME}"]: Check ["{#SERVICE_CHECK_NAME}"]: Status

Current state of health check for the service.

Dependent item consul.service.check.state["{#SERVICE_ID}/{#SERVICE_CHECK_ID}"]

Preprocessing

  • JSON Path: The text is too long. Please see the template.

  • JavaScript: The text is too long. Please see the template.

  • Discard unchanged with heartbeat: 3h

["{#SERVICE_NAME}"]: Check ["{#SERVICE_CHECK_NAME}"]: Output

Current output of health check for the service.

Dependent item consul.service.check.output["{#SERVICE_ID}/{#SERVICE_CHECK_ID}"]

Preprocessing

  • JSON Path: The text is too long. Please see the template.

  • Discard unchanged with heartbeat: 3h

Trigger prototypes for Local node services discovery

Name Description Expression Severity Dependencies and additional info
HashiCorp Consul Node: Aggregated status is 'warning'

Aggregated state of service on the local agent is 'warning'.

last(/HashiCorp Consul Node by HTTP/consul.service.aggregated_state["{#SERVICE_ID}"]) = 1 Warning
HashiCorp Consul Node: Aggregated status is 'critical'

Aggregated state of service on the local agent is 'critical'.

last(/HashiCorp Consul Node by HTTP/consul.service.aggregated_state["{#SERVICE_ID}"]) = 2 Average

LLD rule HTTP API methods discovery

Name Description Type Key and additional info
HTTP API methods discovery

Discovery HTTP API methods specific metrics.

Dependent item consul.http_api_discovery

Preprocessing

  • Prometheus to JSON: consul_api_http{method =~ ".*"}

    ⛔️Custom on fail: Discard value

  • JavaScript: The text is too long. Please see the template.

  • Discard unchanged with heartbeat: 3h

Item prototypes for HTTP API methods discovery

Name Description Type Key and additional info
HTTP request: ["{#HTTP_METHOD}"], p90

The 90 percentile of how long it takes to service the given HTTP request for the given verb.

Dependent item consul.http.api.p90["{#HTTP_METHOD}"]

Preprocessing

  • Prometheus pattern: The text is too long. Please see the template.

    ⛔️Custom on fail: Discard value

HTTP request: ["{#HTTP_METHOD}"], p50

The 50 percentile (median) of how long it takes to service the given HTTP request for the given verb.

Dependent item consul.http.api.p50["{#HTTP_METHOD}"]

Preprocessing

  • Prometheus pattern: The text is too long. Please see the template.

    ⛔️Custom on fail: Discard value

HTTP request: ["{#HTTP_METHOD}"], rate

The number of HTTP request for the given verb per second.

Dependent item consul.http.api.rate["{#HTTP_METHOD}"]

Preprocessing

  • Prometheus pattern: SUM(consul_api_http_count{method = "{#HTTP_METHOD}"})

    ⛔️Custom on fail: Discard value

  • Change per second

LLD rule Raft server metrics discovery

Name Description Type Key and additional info
Raft server metrics discovery

Discover raft metrics for server nodes.

Dependent item consul.raft.server.discovery

Preprocessing

  • JavaScript: The text is too long. Please see the template.

  • Discard unchanged with heartbeat: 3h

Item prototypes for Raft server metrics discovery

Name Description Type Key and additional info
Raft state

Current state of Consul agent.

Dependent item consul.raft.state[{#SINGLETON}]

Preprocessing

  • JSON Path: $.Stats.raft.state

  • Discard unchanged with heartbeat: 3h

Raft state: Leader

Increments when a server becomes a leader.

Dependent item consul.raft.state_leader[{#SINGLETON}]

Preprocessing

  • Prometheus pattern: VALUE(consul_raft_state_leader)

    ⛔️Custom on fail: Discard value

Raft state: Candidate

The number of initiated leader elections.

Dependent item consul.raft.state_candidate[{#SINGLETON}]

Preprocessing

  • Prometheus pattern: VALUE(consul_raft_state_candidate)

    ⛔️Custom on fail: Discard value

Raft: Apply, rate

Incremented whenever a leader first passes a message into the Raft commit process (called an Apply operation).

This metric describes the arrival rate of new logs into Raft per second.

Dependent item consul.raft.apply.rate[{#SINGLETON}]

Preprocessing

  • Prometheus pattern: VALUE(consul_raft_apply)

    ⛔️Custom on fail: Discard value

  • Change per second
Server: Is leader

Tracks if the server is a leader.

Dependent item consul.server.is_leader[{#SINGLETON}]

Preprocessing

  • Prometheus pattern: VALUE(consul_server_isLeader)

    ⛔️Custom on fail: Discard value

gRPC: Active connections

Measures the number of active gRPC connections open on the server.

Dependent item consul.grpc.server_connections[{#SINGLETON}]

Preprocessing

  • Prometheus pattern: VALUE(consul_grpc_server_connections)

    ⛔️Custom on fail: Discard value

gRPC: Active streams

Measures the number of active gRPC streams handled by the server.

Dependent item consul.grpc.server_streams[{#SINGLETON}]

Preprocessing

  • Prometheus pattern: VALUE(consul_grpc_server_streams)

    ⛔️Custom on fail: Discard value

xDS: Active streams

Measures the number of active xDS streams handled by the server, split by protocol version.

Dependent item consul.xds.server_streams[{#SINGLETON}]

Preprocessing

  • Prometheus pattern: SUM(consul_xds_server_streams)

    ⛔️Custom on fail: Discard value

LLD rule Raft leader metrics discovery

Name Description Type Key and additional info
Raft leader metrics discovery

Discover raft metrics for leader nodes.

Dependent item consul.raft.leader.discovery

Preprocessing

  • JavaScript: The text is too long. Please see the template.

  • Discard unchanged with heartbeat: 3h

Item prototypes for Raft leader metrics discovery

Name Description Type Key and additional info
Raft state: Leader last contact, p90

The 90 percentile of how long it takes a leader node to communicate with followers during a leader lease check, in milliseconds.

Dependent item consul.raft.leader_last_contact.p90[{#SINGLETON}]

Preprocessing

  • Prometheus pattern: VALUE(consul_raft_leader_lastContact{quantile="0.9"})

    ⛔️Custom on fail: Discard value

  • JavaScript: The text is too long. Please see the template.

Raft state: Leader last contact, p50

The 50 percentile (median) of how long it takes a leader node to communicate with followers during a leader lease check, in milliseconds.

Dependent item consul.raft.leader_last_contact.p50[{#SINGLETON}]

Preprocessing

  • Prometheus pattern: VALUE(consul_raft_leader_lastContact{quantile="0.5"})

    ⛔️Custom on fail: Discard value

  • JavaScript: The text is too long. Please see the template.

Raft state: Commit time, p90

The 90 percentile time it takes to commit a new entry to the raft log on the leader, in milliseconds.

Dependent item consul.raft.commit_time.p90[{#SINGLETON}]

Preprocessing

  • Prometheus pattern: VALUE(consul_raft_commitTime{quantile="0.9"})

    ⛔️Custom on fail: Discard value

  • JavaScript: The text is too long. Please see the template.

Raft state: Commit time, p50

The 50 percentile (median) time it takes to commit a new entry to the raft log on the leader, in milliseconds.

Dependent item consul.raft.commit_time.p50[{#SINGLETON}]

Preprocessing

  • Prometheus pattern: VALUE(consul_raft_commitTime{quantile="0.5"})

    ⛔️Custom on fail: Discard value

  • JavaScript: The text is too long. Please see the template.

Raft state: Dispatch log, p90

The 90 percentile time it takes for the leader to write log entries to disk, in milliseconds.

Dependent item consul.raft.dispatch_log.p90[{#SINGLETON}]

Preprocessing

  • Prometheus pattern: VALUE(consul_raft_leader_dispatchLog{quantile="0.9"})

    ⛔️Custom on fail: Discard value

  • JavaScript: The text is too long. Please see the template.

Raft state: Dispatch log, p50

The 50 percentile (median) time it takes for the leader to write log entries to disk, in milliseconds.

Dependent item consul.raft.dispatch_log.p50[{#SINGLETON}]

Preprocessing

  • Prometheus pattern: VALUE(consul_raft_leader_dispatchLog{quantile="0.5"})

    ⛔️Custom on fail: Discard value

  • JavaScript: The text is too long. Please see the template.

Raft state: Dispatch log, rate

The number of times a Raft leader writes a log to disk per second.

Dependent item consul.raft.dispatch_log.rate[{#SINGLETON}]

Preprocessing

  • Prometheus pattern: VALUE(consul_raft_leader_dispatchLog_count)

    ⛔️Custom on fail: Discard value

  • Change per second
Raft state: Commit, rate

The number of commits a new entry to the Raft log on the leader per second.

Dependent item consul.raft.commit_time.rate[{#SINGLETON}]

Preprocessing

  • Prometheus pattern: VALUE(consul_raft_commitTime_count)

    ⛔️Custom on fail: Discard value

  • Change per second
Autopilot healthy

Tracks the overall health of the local server cluster. 1 if all servers are healthy, 0 if one or more are unhealthy.

Dependent item consul.autopilot.healthy[{#SINGLETON}]

Preprocessing

  • Prometheus pattern: VALUE(consul_autopilot_healthy)

    ⛔️Custom on fail: Discard value

Autopilot: Failure tolerance

Tracks the number of voting servers that the cluster can lose while continuing to function.

Dependent item consul.autopilot.failure_tolerance[{#SINGLETON}]

Preprocessing

  • Prometheus pattern: VALUE(consul_autopilot_failure_tolerance)

    ⛔️Custom on fail: Discard value

Feedback

Please report any issues with the template at https://support.zabbix.com

You can also provide feedback, discuss the template, or ask for help at ZABBIX forums

Articles and documentation

+ Propose new article

No se encuentra la integración que necesitas?