Best practices for monitoring at-scale with Azure Monitor
Azure Monitor is a comprehensive monitoring solution for collecting, analyzing, and responding to monitoring data from your cloud and on-premises environments.
In large and complex implementations, you need a way to manage your environment at-scale, without having to apply the same configurations, behaviors, or changes to each resource. Using at-scale solutions, you can apply settings to resources as they're created, and you can make changes that are automatically applied to all relevant resources.
Use Azure Policies to implement at-scale solutions
Azure Policy is the most commonly used solution for implementing monitoring at-scale. Azure Policy is a service in Azure that you use to create, assign, and manage policies. These policies enforce different rules and effects over your resources, so those resources stay compliant with your corporate standards and service level agreements. Azure Policy can be used to enforce policies that apply to all resources in your subscription, or to a subset of resources.
For more information, see Azure Policy.
At-scale solutions
The following table describes the solutions you can use to implement monitoring at scale for various scenarios.
At-scale solution | Resources |
---|---|
Use Log Analytics workspace architecture | Design a Log Analytics workspace architecture |
Configure diagnostic settings to collect data | Create diagnostic settings at-scale using Azure Policies and Initiatives |
Configure agents to collect data | Best practices for data collection rule creation and management in Azure Monitor |
Configure alerts and action groups | - You can use Azure policies to easily implement alerting at-scale. You can see how this is implemented with Azure Monitor baseline alerts. - For Virtual machines, you can use Log Analytics to set up 1 alert for each metric. This would cause each metric to be configured with an alert, and when the VM starts sending data to Log Analytics, the metric is already configured for that alert. |
Configure virtual machines as they're added | Use Azure policies to: - Install an Azure Monitor Agent - Create a DCR to collect performance data - Add associations to the DCR. |
Configure Kubernetes clusters as they're added | Use Azure policies to: - Install an Azure Monitor Agent - Create a DCR to collect performance data. - Add associations to the DCR. |