I try to query the metric for DataProtection/BackupVault resource which has two metrics namely BackupHealthEvents and ResourceHealthEvents using the azure rest api(a sample is given below): GET https://management.azure.com/subscriptions/b324c52b-4073-4807-93af-e07d289c093e/resourceGroups/test/providers/Microsoft.DataProtection/BackupVaults/{vaultName}/backupJobs/{jobName}/providers/Microsoft.Insights/metrics?api-version=2018-01-01 It returns an output, but the metric BackupHealthEvents does not return any values even though I have created Backup jobs in the Backup vault

I had seen that not all resources might give metrics by default and we need to manually go and enable it, I saw the 'Diagnostic Setting' option and added it to DataProtection/BackupVault resource where there was an option to add the metric 'Health' for backup vaults as shown in this link. I added the destination as my LA workspace and i still do not understand why I don't get any values for the metric, it returns an empty list. I have probably checked most of the links if any additional configurations are required to get those metrics.

1

There are 1 answers

0
Venkat V On

I added the destination as my LA workspace and i still do not understand why I don't get any values for the metric, it returns an empty list. I have probably checked most of the links if any additional configurations are required to get those metrics.

Here is the KQL query to check Recovery Service Vault metrics in `Log Analytics Workspace.

    AzureMetrics
    | where ResourceProvider == "MICROSOFT.RECOVERYSERVICES"
    | where MetricName == "BackupHealthEvent"

Result:

enter image description here

Note: Azure Backup currently supports the following metrics.

  • 1.Backup Health Events
  • 2.Restore Health Events not Resource Health Events, Refer the Ms
    Doc
    for more details

To check the metric for the Recovery Service Vault in Log Analytics, ensure that you select the 'Metric' option when enabling the Diagnostic Setting, as shown below.

Note: It may take some time to sync the logs to Log Analytics Workspace.

enter image description here

Reference : Monitor the health of your backups using Azure Backup Metrics (preview)