Skip to content

Commit 746aa3b

Browse files
authored
Merge pull request #273634 from SnehaSudhirG/28Apr-CTUpdate
edited the info for PS-Arc-enabledVMs section
2 parents 4522db2 + 1da8c84 commit 746aa3b

File tree

1 file changed

+62
-28
lines changed

1 file changed

+62
-28
lines changed

articles/automation/change-tracking/guidance-migration-log-analytics-monitoring-agent.md

Lines changed: 62 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ author: snehasudhirG
55
services: automation
66
ms.subservice: change-inventory-management
77
ms.topic: conceptual
8-
ms.date: 02/07/2024
8+
ms.date: 05/01/2024
99
ms.author: sudhirsneha
1010
ms.custom:
1111
---
@@ -23,7 +23,12 @@ Using the Azure portal, you can migrate from Change Tracking & Inventory with LA
2323

2424
## Onboarding to Change tracking and inventory using Azure Monitoring Agent
2525

26-
### [Using Azure portal - for single VM](#tab/ct-single-vm)
26+
### [Using Azure portal - Azure single VM](#tab/ct-single-vm)
27+
28+
> [!NOTE]
29+
> To onboard Arc-enabled VMs, use the PowerShell Script. For more information, see the steps listed in tab Using PowerShell script - Arc-enabled VMs.
30+
31+
To onboard through Azure portal, follow these steps:
2732

2833
1. Sign in to the [Azure portal](https://portal.azure.com) and select your virtual machine
2934
1. Under **Operations** , select **Change tracking**.
@@ -35,7 +40,7 @@ Using the Azure portal, you can migrate from Change Tracking & Inventory with LA
3540

3641
:::image type="content" source="media/guidance-migration-log-analytics-monitoring-agent/switch-versions-inline.png" alt-text="Screenshot that shows switching between log analytics and Azure Monitoring Agent after a successful migration." lightbox="media/guidance-migration-log-analytics-monitoring-agent/switch-versions-expanded.png":::
3742

38-
### [Using Azure portal - for Automation account](#tab/ct-at-scale)
43+
### [Using Azure portal - Automation account](#tab/ct-at-scale)
3944

4045
1. Sign in to [Azure portal](https://portal.azure.com) and select your Automation account.
4146
1. Under **Configuration Management**, select **Change tracking** and then select **Configure with AMA**.
@@ -58,7 +63,9 @@ Using the Azure portal, you can migrate from Change Tracking & Inventory with LA
5863

5964
:::image type="content" source="media/guidance-migration-log-analytics-monitoring-agent/switch-versions-inline.png" alt-text="Screenshot that shows switching between log analytics and Azure Monitoring Agent after a successful migration." lightbox="media/guidance-migration-log-analytics-monitoring-agent/switch-versions-expanded.png":::
6065

61-
### [Using PowerShell script](#tab/ps-policy)
66+
### [Using PowerShell script - Arc-enabled VMs](#tab/ps-policy)
67+
68+
To onboard Arc-enabled VMs, follow the steps:
6269

6370
#### Prerequisites
6471

@@ -70,32 +77,59 @@ Follow these steps to migrate using scripts.
7077

7178
#### Migration guidance
7279

73-
1. Install the script and run it to conduct migrations.
74-
1. Ensure the new workspace resource ID is different from the one associated with the Change Tracking and Inventory using the LA version.
75-
1. Migrate settings for the following data types:
76-
- Windows Services
77-
- Linux Files
78-
- Windows Files
79-
- Windows Registry
80-
- Linux Daemons
81-
1. Generate and associate a new DCR to transfer the settings to the Change Tracking and Inventory using AMA.
82-
83-
#### Onboard at scale
84-
85-
Use the [script](https://github.com/mayguptMSFT/AzureMonitorCommunity/blob/master/Azure%20Services/Azure%20Monitor/Agents/Migration%20Tools/DCR%20Config%20Generator/CTDcrGenerator/CTWorkSpaceSettingstoDCR.ps1) to migrate Change tracking workspace settings to a data collection rule.
86-
87-
#### Parameters
88-
89-
**Parameter** | **Required** | **Description** |
90-
--- | --- | --- |
91-
`InputWorkspaceResourceId`| Yes | Resource ID of the workspace associated with Change Tracking & Inventory with Log Analytics. |
92-
`OutputWorkspaceResourceId`| Yes | Resource ID of the workspace associated with Change Tracking & Inventory with Azure Monitoring Agent. |
93-
`OutputDCRName`| Yes | Custom name of the new DCR created. |
94-
`OutputDCRLocation`| Yes | Azure location of the output workspace ID. |
95-
`OutputDCRTemplateFolderPath`| Yes | Folder path where DCR templates are created. |
96-
80+
1. Install the [script](https://github.com/mayguptMSFT/AzureMonitorCommunity/blob/master/Azure%20Services/Azure%20Monitor/Agents/Migration%20Tools/DCR%20Config%20Generator/CTDcrGenerator/CTWorkSpaceSettingstoDCR.ps1) and run it to conduct migrations. The script does the following:
81+
82+
1. It ensures the new workspace resource ID is different from the one associated with the Change Tracking and Inventory using the LA version.
83+
84+
1. It migrates the settings for the following data types:
85+
- Windows Services
86+
- Linux Files
87+
- Windows Files
88+
- Windows Registry
89+
- Linux Daemons
90+
91+
1. The script consists of the following **Parameters** that require an input from you.
92+
93+
**Parameter** | **Required** | **Description** |
94+
--- | --- | --- |
95+
`InputWorkspaceResourceId`| Yes | Resource ID of the workspace associated with Change Tracking & Inventory with Log Analytics. |
96+
`OutputWorkspaceResourceId`| Yes | Resource ID of the workspace associated with Change Tracking & Inventory with Azure Monitoring Agent. |
97+
`OutputDCRName`| Yes | Custom name of the new DCR created. |
98+
`OutputDCRLocation`| Yes | Azure location of the output workspace ID. |
99+
`OutputDCRTemplateFolderPath`| Yes | Folder path where DCR templates are created. |
100+
101+
1. A DCR template is generated when you run the above script and the template is available in `OutputDCRTemplateFolderPath`. You have to associate the new DCR to transfer the settings to the Change Tracking and Inventory using AMA.
102+
103+
1. Sign in to [Azure portal](https://portal.azure.com) and go to **Monitor** and under **Settings**, select **Data Collection Rules**.
104+
1. Select the data collection rule that you have created in Step 1 from the listing page.
105+
1. In the data collection rule page, under **Configurations**, select **Resources** and then select **Add**.
106+
1. In the Select a scope, from Resource types, select Machines-Azure Arc that is connected to the subscription and then select Apply to associate the ctdcr created in Step 1 to the Arc-enabled machine and it will also install the Azure Monitoring Agent extension. For more information, see [Enable Change Tracking and Inventory - for Arc-enabled VMs - using portal/CLI](enable-vms-monitoring-agent.md#enable-change-tracking-and-inventory).
107+
108+
Install the Change Tracking extension as per the OS type for the Arc-enabled VM.
109+
110+
**Linux**
111+
112+
```azurecli
113+
az connectedmachine extension create --name ChangeTracking-Linux --publisher Microsoft.Azure.ChangeTrackingAndInventory --type-handler-version 2.20 --type ChangeTracking-Linux --machine-name XYZ --resource-group XYZ-RG --location X --enable-auto-upgrade
114+
```
115+
116+
**Windows**
117+
118+
```azurecli
119+
az connectedmachine extension create --name ChangeTracking-Windows --publisher Microsoft.Azure.ChangeTrackingAndInventory --type-handler-version 2.20 --type ChangeTracking-Windows --machine-name XYZ --resource-group XYZ-RG --location X --enable-auto-upgrade
120+
```
121+
122+
If the CT logs table schema does not exist, the script mentioned in Step 1 will fail. To troubleshoot, run the following script -
123+
124+
```azurepowershell-interactive
125+
126+
$psWorkspace = Get-AzOperationalInsightsWorkspace -ResourceGroupName $resourceGroup -Name $laws
127+
# Enabling CT solution on LA ws
128+
New-AzMonitorLogAnalyticsSolution -Type ChangeTracking -ResourceGroupName $resourceGroup -Location $psWorkspace.Location -WorkspaceResourceId $psWorkspace.ResourceId
129+
```
97130
---
98131
132+
99133
### Compare data across Log analytics Agent and Azure Monitoring Agent version
100134
101135
After you complete the onboarding to Change tracking with AMA version, select **Switch to CT with AMA** on the landing page to switch across the two versions and compare the following events.

0 commit comments

Comments
 (0)