Available solutions
Azure Backup Jobs by HTTP
Overview
This template is designed to monitor Microsoft Azure Backup Jobs via HTTP. It works without any external scripts and uses the script item.
Requirements
Zabbix version: 7.4 and higher.
Tested versions
This template has been tested on:
- Azure Recovery Services vaults
Configuration
Zabbix should be configured according to the instructions in the Templates out of the box section.
Setup
-
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.
- Link the template to a host.
- 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 vault resource ID. |
|
| {$AZURE.VAULT.PERIOD} | The number of days over which to retrieve backup jobs. |
7 |
| {$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 Backup Jobs", e.g. {$HTTP.TLS.VERIFY:"Azure Backup Jobs"}. |
full |
| {$AZURE.JOBS.FRIENDLY.NAME.MATCHES} | Set the regex string to include backup jobs based on |
.* |
| {$AZURE.JOBS.FRIENDLY.NAME.NOT.MATCHES} | Set the regex string to exclude backup jobs based on |
CHANGE_IF_NEEDED |
| {$AZURE.JOBS.STATUS.MATCHES} | Set the regex string to include backup jobs based on status. |
.* |
| {$AZURE.JOBS.STATUS.NOT.MATCHES} | Set the regex string to exclude backup jobs based on status. |
CHANGE_IF_NEEDED |
| {$AZURE.JOBS.OPERATION.MATCHES} | Set the regex string to include backup jobs based on operation type. |
.* |
| {$AZURE.JOBS.OPERATION.NOT.MATCHES} | Set the regex string to exclude backup jobs based on operation type. |
CHANGE_IF_NEEDED |
Items
| Name | Description | Type | Key and additional info |
|---|---|---|---|
| Get data | Gathers data of the Azure vault. |
Script | azure.vault.data.get |
| Get errors | A list of errors from API requests. |
Dependent item | azure.vault.data.errors Preprocessing
|
| Availability state | The availability status of the resource. 0 - Available - no events detected that affect the health of the resource. 1 - Degraded - your resource detected a loss in performance, although it's still available for use. 2 - Unavailable - the service detected an ongoing platform or non-platform event that affects the health of the resource. 3 - Unknown - Resource Health hasn't received information about the resource for more than 10 minutes. |
Dependent item | azure.vault.availability.state Preprocessing
|
| Availability status detailed | The summary description of the availability status. |
Dependent item | azure.vault.availability.details Preprocessing
|
| Jobs: Total | The number of jobs over the period of |
Dependent item | azure.vault.jobs.total Preprocessing
|
| Jobs: Completed | The number of completed jobs over the period of |
Dependent item | azure.vault.jobs.completed Preprocessing
|
| Jobs: In progress | The number of jobs in progress over the period of |
Dependent item | azure.vault.jobs.in_progress Preprocessing
|
| Jobs: Failed | The number of failed jobs over the period of |
Dependent item | azure.vault.jobs.failed Preprocessing
|
| Jobs: Completed with warnings | The number of jobs completed with warnings over the period of |
Dependent item | azure.vault.jobs.with_warning Preprocessing
|
| Jobs: Cancelled | The number of cancelled jobs over the period of |
Dependent item | azure.vault.jobs.cancelled Preprocessing
|
| Jobs: Backup | The number of backup jobs over the period of |
Dependent item | azure.vault.jobs.backup Preprocessing
|
| Jobs: Restore | The number of restore jobs over the period of |
Dependent item | azure.vault.jobs.restore Preprocessing
|
| Jobs: Deleting backup data | The number of backup data deletion jobs over the period of |
Dependent item | azure.vault.jobs.backup.delete Preprocessing
|
| Jobs: Configuring backup | The number of backup configuration jobs over the period of |
Dependent item | azure.vault.jobs.backup.config Preprocessing
|
Triggers
| Name | Description | Expression | Severity | Dependencies and additional info |
|---|---|---|---|---|
| Azure backup jobs: There are errors in requests to API | Zabbix has received errors in response to API requests. |
length(last(/Azure Backup Jobs by HTTP/azure.vault.data.errors))>0 |
Average | |
| Azure backup jobs: Azure vault is unavailable | The resource state is unavailable. |
last(/Azure Backup Jobs by HTTP/azure.vault.availability.state)=2 |
High | |
| Azure backup jobs: Azure vault is degraded | The resource is in a degraded state. |
last(/Azure Backup Jobs by HTTP/azure.vault.availability.state)=1 |
Average | |
| Azure backup jobs: Azure vault is in unknown state | The resource state is unknown. |
last(/Azure Backup Jobs by HTTP/azure.vault.availability.state)=3 |
Warning | |
| Azure backup jobs: Restore job has appeared | New restore job has appeared. |
change(/Azure Backup Jobs by HTTP/azure.vault.jobs.restore)>0 |
Average | Manual close: Yes |
| Azure backup jobs: Backup data deletion job has appeared | New backup data deletion job has appeared. |
change(/Azure Backup Jobs by HTTP/azure.vault.jobs.backup.delete)>0 |
Warning | Manual close: Yes |
| Azure backup jobs: Backup configuration job has appeared | New backup configuration job has appeared. |
change(/Azure Backup Jobs by HTTP/azure.vault.jobs.backup.config)>0 |
Info | Manual close: Yes |
LLD rule Azure backup job discovery
| Name | Description | Type | Key and additional info |
|---|---|---|---|
| Azure backup job discovery | List of backup jobs in the vault. |
Dependent item | azure.vault.job.discovery Preprocessing
|
Item prototypes for Azure backup job discovery
| Name | Description | Type | Key and additional info |
|---|---|---|---|
| Job status [{#JOB.FRIENDLY.NAME}, {#JOB.NAME}] | Job status. Possible values: 0 - Unknown 1 - In progress 2 - Queued 3 - Completed 4 - Completed with warnings 5 - Failed 6 - Cancelled 7 - Expired |
Dependent item | azure.vault.job.status[{#JOB.NAME}] Preprocessing
|
Trigger prototypes for Azure backup job discovery
| Name | Description | Expression | Severity | Dependencies and additional info |
|---|---|---|---|---|
| Azure backup jobs: Job failed [{#JOB.NAME}] | Job has received "Failed" status. |
last(/Azure Backup Jobs by HTTP/azure.vault.job.status[{#JOB.NAME}])=5 |
High | Manual close: Yes |
| Azure backup jobs: Job cancelled [{#JOB.NAME}] | Job has received "Cancelled" status. |
last(/Azure Backup Jobs by HTTP/azure.vault.job.status[{#JOB.NAME}])=6 |
Average | Manual close: Yes |
| Azure backup jobs: Job completed with warnings [{#JOB.NAME}] | Job has received "Completed with warnings" status. |
last(/Azure Backup Jobs by HTTP/azure.vault.job.status[{#JOB.NAME}])=4 |
Warning | Manual close: Yes |
| Azure backup jobs: Job expired [{#JOB.NAME}] | Job has received "Expired" status. |
last(/Azure Backup Jobs by HTTP/azure.vault.job.status[{#JOB.NAME}])=7 |
Average | Manual close: Yes |
| Azure backup jobs: Job status unknown [{#JOB.NAME}] | Job has received "Unknown" status. |
last(/Azure Backup Jobs by HTTP/azure.vault.job.status[{#JOB.NAME}])=0 |
Average | Manual close: Yes |
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