You are viewing a free preview of this lesson.
Subscribe to unlock all 10 lessons in this course and every other course on LearningBro.
Monitoring is the practice of collecting, analysing, and acting on telemetry data from your cloud infrastructure and applications. In Azure, monitoring is essential for maintaining the health, performance, and security of your workloads. Without monitoring, you are operating blind — unable to detect failures, understand usage patterns, or optimise costs.
Cloud workloads are dynamic. Resources scale up and down, deployments happen frequently, and failures can cascade across services. Monitoring addresses several critical needs:
Without proper monitoring:
Azure provides a comprehensive set of monitoring tools that work together:
| Service | Purpose |
|---|---|
| Azure Monitor | The unified monitoring platform — collects metrics, logs, and traces |
| Log Analytics | Query engine for log data using Kusto Query Language (KQL) |
| Application Insights | Application performance management (APM) for web apps |
| Azure Activity Log | Control-plane audit trail — who did what and when |
| Azure Advisor | Personalised recommendations for cost, security, and reliability |
| Azure Service Health | Status of Azure services and planned maintenance |
| Microsoft Sentinel | Cloud-native SIEM for security monitoring |
| Azure Network Watcher | Network diagnostics and monitoring |
Azure Monitor (unified platform)
/ | \
Metrics Logs Traces
| | |
Metrics Explorer Log Analytics Application Insights
| | |
Alerts Workbooks App Map
Azure Monitor sits at the centre. It ingests data from virtually every Azure resource and provides the foundation for alerting, visualisation, and analysis.
Azure Monitor collects three types of telemetry:
| Type | Description | Examples |
|---|---|---|
| Metrics | Numerical time-series data collected at regular intervals | CPU percentage, memory usage, request count |
| Logs | Timestamped event records with structured or unstructured data | Application errors, audit events, diagnostic output |
| Traces | Records of a request's path through distributed services | End-to-end transaction flow across microservices |
Telemetry data flows into specific destinations:
| Destination | Data Type | Retention |
|---|---|---|
| Azure Monitor Metrics | Platform and custom metrics | 93 days (standard) |
| Log Analytics Workspace | Logs and traces | Configurable (30 days to 2 years+) |
| Storage Account | Archived logs and metrics | Unlimited (you manage lifecycle) |
| Event Hubs | Streaming telemetry to external systems | Real-time |
Every Azure resource type exposes telemetry through its resource provider. To route this telemetry to Log Analytics, a storage account, or Event Hubs, you configure diagnostic settings:
# Enable diagnostic settings for a storage account
az monitor diagnostic-settings create \
--name "send-to-log-analytics" \
--resource /subscriptions/<sub>/resourceGroups/<rg>/providers/Microsoft.Storage/storageAccounts/<account> \
--workspace /subscriptions/<sub>/resourceGroups/<rg>/providers/Microsoft.OperationalInsights/workspaces/<workspace> \
--logs '[{"category": "StorageRead", "enabled": true}]' \
--metrics '[{"category": "Transaction", "enabled": true}]'
Azure Service Health keeps you informed about the status of Azure services that affect your resources:
| Feature | Description |
|---|---|
| Service issues | Active problems affecting Azure services in your regions |
| Planned maintenance | Upcoming maintenance that may impact your resources |
| Health advisories | Changes in Azure services that require your attention |
| Health history | A 90-day record of past incidents |
You can configure Service Health alerts to be notified when issues affect the specific services and regions you use.
Azure Advisor is a free, personalised recommendation engine that analyses your resource configuration and usage:
| Category | Example Recommendations |
|---|---|
| Reliability | Enable zone redundancy, configure backup policies |
| Security | Enable MFA, restrict public network access |
| Performance | Upgrade to Premium SSD, enable caching |
| Cost | Resize underutilised VMs, delete unused public IPs |
| Operational Excellence | Fix expiring certificates, enable diagnostic settings |
Advisor recommendations are based on Microsoft best practices and are continuously updated as your resources change.
A well-designed monitoring strategy covers four layers:
Monitor the health of your Azure resources:
Monitor the behaviour of your applications:
Monitor for threats and compliance:
Monitor spending and optimise costs:
To begin monitoring an Azure environment:
# Create a Log Analytics workspace
az monitor log-analytics workspace create \
--resource-group rg-monitoring \
--workspace-name law-production \
--location uksouth \
--retention-time 90
Azure provides a rich monitoring ecosystem centred on Azure Monitor. By collecting metrics, logs, and traces from your infrastructure and applications, you gain the visibility needed to detect issues, diagnose root causes, and optimise performance and cost. A good monitoring strategy covers infrastructure, application, security, and cost layers. In the next lesson, we will dive deep into Azure Monitor metrics and alerts — the foundation of proactive monitoring.