Grafana for Azure
ARM template for adding an VM with a fully automated bootstrap script to create monitoring that automatically connects to Azure monitor (data source) for metrics and allows users easy viewing of key metrics for Azure resources.
Video
Creation Proces:
- Create a Resource groups
- Create Azure Grafana ARM template
- Run the ARM template
- Edit Subscription IAM - add Role assignment: Monitor Reade
Resources creation for monitoring:
- Resource group
- Virtual network
- Network Interface
- Network security group
- Virtual machine UserData
- Public IP address
- Disk
Grafana previsioned Data sources:
- Azure Monitor for getting metrics on network resources. Credentials will be with User assigned Managed Identity.
- InfluxDB data source in combination with Telegraf for getting metrics on service UpTime.
Custom dashboard for Azure resources.
Running ARM temp from Azure CLI
Log in to Azure
1
az login
Set the right subscription
1
az account set --subscription "your subscription id"
Create the Resource group
1 2
az account list-locations az group create --name "resource-group" --location "your location"
Deploy the ARM template
1
az group deployment create --name "name of your deployment" --resource-group "resource-group" --template-file "./azuredeploy.json"
In Azure CLI fill in “Linux OS Password” parameter
- At least 12 characters
- A mixture of both uppercase and lowercase letters
- A mixture of letters and numbers
- Go to portal.azure.com and add the role assignment “Monitoring Reader” to the Subscription you want to monitor.
- Visit GrafanaVM IP address (DNS name) to access the Grafana
- User: Admin
- Password: admin
This post is licensed under CC BY 4.0 by the author.
Comments powered by Disqus.