Ensure that Diagnostic Settings exist for exporting activity logs from your Azure subscriptions and appropriate resources. Diagnostic settings control how a diagnostic log is exported and stored. By default, logs are retained only for 90 days in the Azure portal. These settings are available for each individual resource within a subscription and should be configured for all appropriate resources in your environment to provide comprehensive visibility into security and operational activities.
excellence
A diagnostic setting controls how a diagnostic log is exported. Without properly configured diagnostic settings, organizations lack the ability to retain and analyze activity logs beyond the default 90-day period. Configuring diagnostic settings ensures that activity logs are exported to appropriate destinations such as Log Analytics workspaces for querying and analysis, storage accounts for long-term archival, Event Hubs for SIEM integration, or partner solutions for third-party monitoring. This enables security teams to detect anomalies, track administrative changes, monitor policy violations, and maintain comprehensive audit trails required by regulatory frameworks.
Enabling diagnostic settings will incur additional costs for log storage and may require monitoring tools and infrastructure to process the exported logs. Organizations should plan for increased storage consumption, especially when archiving logs to storage accounts with long retention periods. Additionally, streaming logs to Event Hubs or sending them to Log Analytics workspaces will generate additional costs based on data ingestion rates. Organizations must also allocate resources to configure and maintain diagnostic settings across all subscriptions and resources, which can be operationally intensive in large environments.
Audit
To determine if diagnostic settings are configured for your Azure subscriptions and resources, perform the following operations:
Remediation / Resolution
To create and configure diagnostic settings for your Microsoft Azure subscriptions and resources, perform the following operations:
References
- Azure Official Documentation
- Azure Monitor data sources and data collection methods
- Diagnostic settings in Azure Monitor
- Activity log in Azure Monitor
- Resource logs in Azure Monitor
- LT-3: Enable logging for security investigation
- Azure Command Line Interface (CLI) Documentation
- az account list
- az monitor diagnostic-settings
- az monitor diagnostic-settings list
- az monitor diagnostic-settings create
- az monitor diagnostic-settings subscription list
- az monitor diagnostic-settings subscription create
- az monitor diagnostic-settings categories list