Edit

Share via


Create data collection rule for Azure Change Tracking and Inventory

When you enable Change Tracking in the Azure portal using the Azure Monitor Agent (AMA), the process automatically creates a Data Collection Rule (DCR). This rule will appear in the resource group with a name in the format ct-dcr-aaaaaaaaa. After the rule is created, add the required resources.

This article explains how to explicitly create a Data Collection Rule for Azure Change Tracking and Inventory (CTI).

To enable Azure CTI from the Azure portal, see Quickstart: Enable Azure Change Tracking and Inventory.

Create DCR

A DCR defines what data to collect from sources, how to transform it, and where to send it (like Log Analytics).

To create a DCR, follow these steps:

  1. Download CtDcrCreation.json file on your machine.

  2. Sign in to the Azure portal and in the search bar, enter Deploy a custom template.

  3. On the Custom deployment pane > select a template tab > select Build your own template in the editor. Screenshot to get started with building a template.

  4. Select Save to proceed to the next tab.

  5. On the Basics tab > select Edit template, select Load file to upload the CtDcrCreation.json file.

  6. Select Save.

  7. On the Basics tab, provide Subscription and Resource group where you want to deploy the Data Collection Rule. The Data Collection Rule Name is optional.

    Screenshot to provide subscription and resource group details to deploy data collection rule.

    Note

    • The resource group must be same as the resource group associated with the Log Analytic workspace ID chosen here.
    • Ensure that the name of your Data Collection Rule is unique in that resource group, else the deployment will overwrite the existing Data Collection Rule.
    • The Log Analytics Workspace Resource ID specifies the Azure resource ID of the Log Analytics workspace used to store change tracking data. Ensure that location of workspace is from the Change tracking supported regions
  8. Select Next : Review + create >.

  9. On the Review + create tab > Select Create to initiate the deployment of CtDcrCreation.

  10. After the deployment is complete, select CtDcr-Deployment to see the DCR Name. Use the Resource ID of the newly created Data Collection Rule for Azure CTI deployment through policy.

    Screenshot of deployment notification.

Note

After creating the Data Collection Rule using the Azure Monitor Agent's change tracking schema, ensure that you don't add any Data Sources to this rule. This can cause Azure CTI to fail. You must only add new Resources in this section.

Next steps