Azure Container Apps

This template is designed to monitor Microsoft Azure Container Apps via HTTP.

Dostupná řešení

Zabbix version 8.0
Download

Azure Container Apps by HTTP

Overview

This template is designed to monitor Microsoft Azure Container Apps via HTTP. It works without any external scripts and uses the script item.

Requirements

Zabbix version: 8.0 and higher.

Tested versions

This template has been tested on:

  • Azure Container Apps

Configuration

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

Setup

  1. Create an Azure service principal via the Azure command-line interface (Azure CLI) for your subscription.

    az ad sp create-for-rbac --name zabbix --role reader --scope /subscriptions/<subscription_id>

See Azure documentation for more details.

  1. Link the template to a host.
  2. Configure the macros: {$AZURE.APP.ID}, {$AZURE.PASSWORD}, {$AZURE.TENANT.ID}, {$AZURE.SUBSCRIPTION.ID}, and {$AZURE.RESOURCE.ID}.

Macros used

Name Description Default
{$AZURE.SUBSCRIPTION.ID}

Microsoft Azure subscription ID.

{$AZURE.TENANT.ID}

Microsoft Azure tenant ID.

{$AZURE.APP.ID}

The App ID of Microsoft Azure.

{$AZURE.PASSWORD}

Microsoft Azure password.

{$AZURE.RESOURCE.ID}

Microsoft Azure container app resource ID.

{$AZURE.DATA.TIMEOUT}

API response timeout.

15s
{$AZURE.PROXY}

Sets the HTTP proxy value. If this macro is empty, then no proxy is used.

{$HTTP.TLS.VERIFY}

TLS certificate verification for script items: "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 "Azure Container Apps", e.g. {$HTTP.TLS.VERIFY:"Azure Container Apps"}.

full
{$AZURE.CONTAINER_APP.JVM.METRICS}

Enable Java virtual machine metric collection. Useful for container apps with Java development stack.

false
{$AZURE.CONTAINER_APP.CPU.WARN}

Warning threshold for CPU utilization.

75
{$AZURE.CONTAINER_APP.CPU.CRIT}

Critical threshold for CPU utilization.

90
{$AZURE.CONTAINER_APP.MEMORY.WARN}

Warning threshold for memory utilization.

75
{$AZURE.CONTAINER_APP.MEMORY.CRIT}

Critical threshold for memory utilization.

90
{$AZURE.CONTAINER_APP.GPU.WARN}

Warning threshold for GPU utilization.

75
{$AZURE.CONTAINER_APP.GPU.CRIT}

Critical threshold for GPU utilization.

90
{$AZURE.CONTAINER_APP.REBOOT.WARN}

Threshold for amount of reboots per minute for a replica.

1
{$AZURE.CONTAINER_APP.RESPONSE.WARN}

Threshold for average response time threshold, in milliseconds.

5000
{$AZURE.CONTAINER_APP.GC.ACTIONS.WARN}

Threshold for amount of Java garbage collectors.

10
{$AZURE.CONTAINER_APP.GC.DURATION.WARN}

Threshold for duration of Java garbage collectors, in milliseconds.

500
{$AZURE.CONTAINER_APP.THREAD.COUNT.WARN}

Threshold for amount of threads in Java virtual machine.

500

Items

Name Description Type Key and additional info
Get data

Gathers data of the Azure container app.

Script azure.container_app.data.get
Get data, errors

A list of errors from API requests.

Dependent item azure.container_app.data.errors

Preprocessing

  • JSON Path: $.error

    ⛔️Custom on fail: Set value to: ``

  • Discard unchanged with heartbeat: 1h

Provisioning state

The provisioning state of the container app.

0 - Unknown

1 - In progress

2 - Succeeded

3 - Failed

4 - Canceled

5 - Deleting

Dependent item azure.container_app.provisioning.state

Preprocessing

  • JSON Path: $.overview.properties.provisioningState

    ⛔️Custom on fail: Set value to: Unknown

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

  • Discard unchanged with heartbeat: 1h

Running status

The current state of the container app.

0 - Unknown

1 - Progressing (container app is transitioning between Stopped and Running)

2 - Running

3 - Stopped

4 - Suspended

5 - Ready

Dependent item azure.container_app.running.status

Preprocessing

  • JSON Path: $.overview.properties.runningStatus

    ⛔️Custom on fail: Set value to: Unknown

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

  • Discard unchanged with heartbeat: 1h

Cores: Usage

CPU consumed by the container app, in cores.

Dependent item azure.container_app.cores.usage

Preprocessing

  • JSON Path: $.metrics.UsageNanoCores

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Custom multiplier: 1e-09

  • Discard unchanged with heartbeat: 1h

Memory: Used

Container app working set memory used, in bytes.

Dependent item azure.container_app.memory.bytes

Preprocessing

  • JSON Path: $.metrics.WorkingSetBytes

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

Network: Transmitted bytes

Bytes transmitted by the container app.

Dependent item azure.container_app.bytes.tx

Preprocessing

  • JSON Path: $.metrics.TxBytes

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

Network: Received bytes

Bytes received by the container app.

Dependent item azure.container_app.bytes.rx

Preprocessing

  • JSON Path: $.metrics.RxBytes

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

Requests: Processed

Requests processed.

Dependent item azure.container_app.requests.processed

Preprocessing

  • JSON Path: $.metrics.Requests

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

Replica: Restarts

The number of times the replica has restarted since the last check.

Dependent item azure.container_app.restart.count

Preprocessing

  • JSON Path: $.metrics.RestartCount

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Simple change
  • Discard unchanged with heartbeat: 1h

Replica: Count

Number of replicas.

Dependent item azure.container_app.replica.count

Preprocessing

  • JSON Path: $.metrics.Replicas

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

GPU: Utilization

GPU utilization, in percent.

Dependent item azure.container_app.utilization.gpu

Preprocessing

  • JSON Path: $.metrics.GpuUtilizationPercentage

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

Cores: Reserved, for revisions

Number of reserved cores for container app revisions.

Dependent item azure.container_app.cores.reserved.revisions

Preprocessing

  • JSON Path: $.metrics.CoresQuotaUsed

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

Cores: Reserved, total

Number of total reserved cores for the container app.

Dependent item azure.container_app.cores.reserved.total

Preprocessing

  • JSON Path: $.metrics.TotalCoresQuotaUsed

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

Connection timeouts

Total connection timeouts.

Dependent item azure.container_app.connection.timeouts

Preprocessing

  • JSON Path: $.metrics.ResiliencyConnectTimeouts

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

Requests: Retries

Total request retries.

Dependent item azure.container_app.requests.retries

Preprocessing

  • JSON Path: $.metrics.ResiliencyRequestRetries

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

Requests: Timed out

Total requests that timed out waiting for a response.

Dependent item azure.container_app.requests.timeouts

Preprocessing

  • JSON Path: $.metrics.ResiliencyRequestTimeouts

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

Requests: Pending

Total requests pending a connection pool connection.

Dependent item azure.container_app.requests.pending

Preprocessing

  • JSON Path: $.metrics.ResiliencyRequestsPendingConnectionPool

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

Ejected hosts

Number of currently ejected hosts.

Dependent item azure.container_app.ejection.hosts

Preprocessing

  • JSON Path: $.metrics.ResiliencyEjectedHosts

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

Ejections, aborted

Number of ejections aborted due to the max ejection %.

Dependent item azure.container_app.ejection.aborted

Preprocessing

  • JSON Path: $.metrics.ResiliencyEjectionsAborted

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

Response time

Average response time per status code.

Dependent item azure.container_app.response.time

Preprocessing

  • JSON Path: $.metrics.ResponseTime

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Custom multiplier: 0.001

  • Discard unchanged with heartbeat: 1h

CPU: Utilization

CPU utilization, in percent.

Dependent item azure.container_app.utilization.cpu

Preprocessing

  • JSON Path: $.metrics.CpuPercentage

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

Memory: Utilization

Memory utilization, in percent.

Dependent item azure.container_app.utilization.memory

Preprocessing

  • JSON Path: $.metrics.MemoryPercentage

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

Triggers

Name Description Expression Severity Dependencies and additional info
Azure container Apps: There are errors in requests to API

Zabbix has received errors in response to API requests.

length(last(/Azure Container Apps by HTTP/azure.container_app.data.errors))>0 Average
Azure container Apps: Azure container app failed

The resource failed.

last(/Azure Container Apps by HTTP/azure.container_app.provisioning.state)=3 High
Azure container Apps: Azure container app is canceled

The resource is in the Canceled state.

last(/Azure Container Apps by HTTP/azure.container_app.provisioning.state)=4 Average
Azure container Apps: Azure container app is being deleted

The resource deletion process is happening.

last(/Azure Container Apps by HTTP/azure.container_app.provisioning.state)=5 High
Azure container Apps: Azure container app is in unknown state

The resource state is Unknown.

last(/Azure Container Apps by HTTP/azure.container_app.provisioning.state)=0 Warning
Azure container Apps: Azure container app stopped

The resource stopped.

last(/Azure Container Apps by HTTP/azure.container_app.running.status)=3 High
Azure container Apps: Azure container app suspended

The resource is suspended.

last(/Azure Container Apps by HTTP/azure.container_app.running.status)=4 Average
Azure container Apps: Azure container app progressing

The resource is transitioning between Stopped and Running states.

last(/Azure Container Apps by HTTP/azure.container_app.running.status)=1 Warning
Azure container Apps: Azure container app status is unknown

The status of the resource is Unknown.

last(/Azure Container Apps by HTTP/azure.container_app.running.status)=0 Warning
Azure container Apps: Replica reboots too often

A container app replica is restarting repeatedly within a defined time window.

avg(/Azure Container Apps by HTTP/azure.container_app.restart.count,3m)>{$AZURE.CONTAINER_APP.REBOOT.WARN} Warning
Azure container Apps: GPU utilization is high

GPU usage has exceeded the warning threshold.

max(/Azure Container Apps by HTTP/azure.container_app.utilization.gpu,3m)>{$AZURE.CONTAINER_APP.GPU.WARN} Warning Depends on:
  • Azure container Apps: GPU utilization is critical
Azure container Apps: GPU utilization is critical

GPU usage has reached a critical threshold.

max(/Azure Container Apps by HTTP/azure.container_app.utilization.gpu,3m)>{$AZURE.CONTAINER_APP.GPU.CRIT} Average
Azure container Apps: Container response time is too high

The average response time of the container app has exceeded the acceptable limit.

max(/Azure Container Apps by HTTP/azure.container_app.response.time,3m)>{$AZURE.CONTAINER_APP.RESPONSE.WARN} Warning
Azure container Apps: CPU utilization is high

CPU usage has exceeded the warning threshold.

max(/Azure Container Apps by HTTP/azure.container_app.utilization.cpu,3m)>{$AZURE.CONTAINER_APP.CPU.WARN} Warning Depends on:
  • Azure container Apps: CPU utilization is critical
Azure container Apps: CPU utilization is critical

CPU usage has reached a critical threshold.

max(/Azure Container Apps by HTTP/azure.container_app.utilization.cpu,3m)>{$AZURE.CONTAINER_APP.CPU.CRIT} Average
Azure container Apps: Memory utilization is high

Memory consumption has exceeded the warning threshold.

max(/Azure Container Apps by HTTP/azure.container_app.utilization.memory,3m)>{$AZURE.CONTAINER_APP.MEMORY.WARN} Warning Depends on:
  • Azure container Apps: Memory utilization is critical
Azure container Apps: Memory utilization is critical

Memory usage has reached a critical threshold.

max(/Azure Container Apps by HTTP/azure.container_app.utilization.memory,3m)>{$AZURE.CONTAINER_APP.MEMORY.CRIT} Average

LLD rule Java metrics discovery

Name Description Type Key and additional info
Java metrics discovery

Java metric discovery based on the {$AZURE.CONTAINER_APP.JVM.METRICS} macro.

Script azure.container_app.jvm_metrics.discovery

Item prototypes for Java metrics discovery

Name Description Type Key and additional info
JVM: Memory: Used, total{#SINGLETON}

Total amount of memory used by heap or non-heap (in bytes).

Dependent item azure.container_app.jvm.memory.used.total[{#SINGLETON}]

Preprocessing

  • JSON Path: $.metrics.JvmMemoryTotalUsed

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

JVM: Memory: Committed, total{#SINGLETON}

Total amount of memory guaranteed to be available for heap or non-heap (in bytes).

Dependent item azure.container_app.jvm.memory.committed.total[{#SINGLETON}]

Preprocessing

  • JSON Path: $.metrics.JvmMemoryTotalCommitted

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

JVM: Memory: Limit, total{#SINGLETON}

Total amount of maximum obtainable memory for heap or non-heap (in bytes).

Dependent item azure.container_app.jvm.memory.limit.total[{#SINGLETON}]

Preprocessing

  • JSON Path: $.metrics.JvmMemoryTotalLimit

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

JVM: Memory: Used{#SINGLETON}

Amount of memory used by each pool (in bytes).

Dependent item azure.container_app.jvm.memory.used[{#SINGLETON}]

Preprocessing

  • JSON Path: $.metrics.JvmMemoryUsed

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

JVM: Memory: Committed{#SINGLETON}

Amount of memory guaranteed to be available for each pool (in bytes).

Dependent item azure.container_app.jvm.memory.committed[{#SINGLETON}]

Preprocessing

  • JSON Path: $.metrics.JvmMemoryCommitted

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

JVM: Memory: Limit{#SINGLETON}

Amount of maximum obtainable memory for each pool (in bytes).

Dependent item azure.container_app.jvm.memory.limit[{#SINGLETON}]

Preprocessing

  • JSON Path: $.metrics.JvmMemoryLimit

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

JVM: GC: Actions{#SINGLETON}

Count of JVM garbage collection actions.

Dependent item azure.container_app.jvm.gc.actions[{#SINGLETON}]

Preprocessing

  • JSON Path: $.metrics.JvmGcCount

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

JVM: GC: Duration{#SINGLETON}

Duration of JVM garbage collection actions (in milliseconds).

Dependent item azure.container_app.jvm.gc.duration[{#SINGLETON}]

Preprocessing

  • JSON Path: $.metrics.JvmGcDuration

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Custom multiplier: 0.001

  • Discard unchanged with heartbeat: 1h

JVM: Threads{#SINGLETON}

Number of executing platform threads.

Dependent item azure.container_app.jvm.thread.count[{#SINGLETON}]

Preprocessing

  • JSON Path: $.metrics.JvmThreadCount

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

JVM: Buffers: Usage{#SINGLETON}

Amount of memory used by buffers, such as direct memory (in bytes).

Dependent item azure.container_app.jvm.buffers.usage[{#SINGLETON}]

Preprocessing

  • JSON Path: $.metrics.JvmBufferMemoryUsage

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

JVM: Buffers: Limit{#SINGLETON}

Amount of total memory capacity of buffers (in bytes).

Dependent item azure.container_app.jvm.buffers.limit[{#SINGLETON}]

Preprocessing

  • JSON Path: $.metrics.JvmBufferMemoryLimit

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

JVM: Buffers: Count{#SINGLETON}

Number of buffers in the memory pool.

Dependent item azure.container_app.jvm.buffers.count[{#SINGLETON}]

Preprocessing

  • JSON Path: $.metrics.JvmBufferCount

  • Matches regular expression: ^\d+$

    ⛔️Custom on fail: Discard value

  • Discard unchanged with heartbeat: 1h

Trigger prototypes for Java metrics discovery

Name Description Expression Severity Dependencies and additional info
Azure container Apps: Garbage collector action count is high

Garbage collection is running too frequently.

avg(/Azure Container Apps by HTTP/azure.container_app.jvm.gc.actions[{#SINGLETON}],3m)>{$AZURE.CONTAINER_APP.GC.ACTIONS.WARN} Warning
Azure container Apps: Garbage collector duration is high

Garbage collection duration has exceeded the warning threshold.

avg(/Azure Container Apps by HTTP/azure.container_app.jvm.gc.duration[{#SINGLETON}],3m)>{$AZURE.CONTAINER_APP.GC.DURATION.WARN} Warning
Azure container Apps: JVM thread amount is high

Active JVM thread count has exceeded the warning threshold.

avg(/Azure Container Apps by HTTP/azure.container_app.jvm.thread.count[{#SINGLETON}],3m)>{$AZURE.CONTAINER_APP.THREAD.COUNT.WARN} Warning

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

Články a dokumentace

+ Navrhněte nový článek

Nenašli jste integraci, kterou potřebujete?