I have 0 experience using grafana and its agent.
The goal is to read matrices from Azure monitor and push it to Grafana cloud using alloy.
I have configured for several resource types all looks good under grafana metrics dashboard. But only for the resource type “Microsoft.Compute/virtualMachines” CPU and MEM metrics has gap in it randomly. What can be the issue, the same resource has proper value when seen under azure portal. Below us my configuration
And I dont want to use Azure Monitor Data source. Using alloy is the requirement.
prometheus.exporter.azure "virtual_machines" {
subscriptions = ["SUBSCRIPTIONHERE"]
resource_type = "Microsoft.Compute/virtualMachines"
metrics = [
"Available Memory Percentage",
"Percentage CPU",
]
metric_aggregations = [
"Average",
"Maximum",
"Minimum",
]
regions = ["westeurope"]
}
prometheus.scrape "integrations_azure_exporter_virtual_machines" {
targets = prometheus.exporter.azure.virtual_machines.targets
forward_to = [prometheus.remote_write.metrics_hosted_prometheus.receiver]
scrape_interval = "60s"
job_name = "integrations/azure_exporter_virtual_machines"
}
What am I missing here. Thanks