Other Articles

General – Enable Auto Provisioning Log Analytics

This check ensures that automatic provisioning of Log Analytics is enabled in Microsoft Defender for Cloud.

Check Details

  • Resource: Microsoft Defender for Cloud
  • Check: Ensure Auto Provisioning of Log Analytics Is Enabled
  • Risk: If automatic provisioning is disabled, required monitoring agents may not be deployed to resources.

Remediation via Azure Portal

  1. Log in to the Azure Portal. Azure Portal dashboard
  2. Navigate to Microsoft Defender for Cloud. Microsoft Defender for Cloud overview
  3. In the left-hand menu, select Environment settings. Defender for Cloud environment settings
  4. Select the relevant Subscription. Defender for Cloud subscription
  5. Under Settings, select Auto provisioning. Auto provisioning settings
  6. Ensure Log Analytics agent / Monitoring agent is set to On.
  7. Click Save to apply the configuration.

Remediation via Azure CLI

  1. Open Azure Cloud Shell or a local terminal with Azure CLI installed. Azure Cloud Shell
  2. Check the current auto provisioning status:

    az security auto-provisioning-setting show \
     --name default
    
  3. Enable automatic provisioning:

    az security auto-provisioning-setting update \
     --name default \
     --auto-provision On
    
  4. Verify the setting is enabled:

    az security auto-provisioning-setting show \
     --name default \
     --query autoProvision
    

The output should confirm that the value is set to On. If the setting is already enabled, no further action is required.