Skip to content

Commit 84435e9

Browse files
authored
Merge pull request #176657 from MGoedtel/task1886704
updated steps in remove VM article
2 parents 009c9ff + 78c96ed commit 84435e9

File tree

2 files changed

+47
-21
lines changed

2 files changed

+47
-21
lines changed

articles/automation/change-tracking/remove-vms-from-change-tracking.md

Lines changed: 23 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,42 @@
11
---
2-
title: Remove VMs from Azure Automation Change Tracking and Inventory
3-
description: This article tells how to remove VMs from Change Tracking and Inventory.
2+
title: Remove machines from Azure Automation Change Tracking and Inventory
3+
description: This article tells how to remove Azure and non-Azure machines from Change Tracking and Inventory.
44
services: automation
55
ms.subservice: change-inventory-management
66
ms.topic: conceptual
7-
ms.date: 05/26/2021
7+
ms.date: 10/20/2021
88
---
99

10-
# Remove VMs from Change Tracking and Inventory
10+
# Remove machines from Change Tracking and Inventory
1111

12-
When you're finished tracking changes on the VMs in your environment, you can stop managing them with the [Change Tracking and Inventory](overview.md) feature. To stop managing them, you will edit the saved search query `MicrosoftDefaultComputerGroup` in your Log Analytics workspace that is linked to your Automation account.
12+
When you're finished tracking changes on your Azure or non-Azure machines in your environment, you can stop managing them with the [Change Tracking and Inventory](overview.md) feature. To stop managing them, you will edit the saved search query `MicrosoftDefaultComputerGroup` in your Log Analytics workspace that is linked to your Automation account.
1313

1414
## Sign into the Azure portal
1515

1616
Sign in to the [Azure portal](https://portal.azure.com).
1717

18-
## To remove your VMs
18+
## To remove your machines
1919

2020
1. In the Azure portal, launch **Cloud Shell** from the top navigation of the Azure portal. If you are unfamiliar with Azure Cloud Shell, see [Overview of Azure Cloud Shell](../../cloud-shell/overview.md).
2121

22-
2. Use the following command to identify the UUID of a machine that you want to remove from management.
22+
2. Use the following method to identify the UUID of an Azure virtual machine or non-Azure machine that you want to remove from management.
2323

24-
```azurecli
25-
az vm show -g MyResourceGroup -n MyVm -d
26-
```
24+
# [Azure VM](#tab/azure-vm)
25+
26+
```azurecli
27+
az vm show -g MyResourceGroup -n MyVm -d
28+
```
29+
30+
# [Non-Azure machine](#tab/non-azure-machine)
31+
32+
```kusto
33+
Heartbeat
34+
| where TimeGenerated > ago(30d)
35+
| where ResourceType == "machines" and (ComputerEnvironment == "Non-Azure")
36+
| summarize by Computer, VMUUID
37+
```
38+
39+
---
2740

2841
3. In the Azure portal, navigate to **Log Analytics workspaces**. Select your workspace from the list.
2942

articles/automation/update-management/remove-vms.md

Lines changed: 24 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,41 @@
11
---
2-
title: Remove VMs from Azure Automation Update Management
3-
description: This article tells how to remove machines managed with Update Management.
2+
title: Remove machines from Azure Automation Update Management
3+
description: This article tells how to remove Azure and non-Azure machines managed with Update Management.
44
services: automation
55
ms.topic: conceptual
6-
ms.date: 06/03/2021
6+
ms.date: 10/20/2021
77
ms.custom: mvc
88
---
99
# Remove VMs from Update Management
1010

11-
When you're finished managing updates on your VMs in your environment, you can stop managing VMs with the [Update Management](overview.md) feature. To stop managing them, you will edit the saved search query `MicrosoftDefaultComputerGroup` in your Log Analytics workspace that is linked to your Automation account.
11+
When you're finished managing updates on your Azure or non-Azure machines in your environment, you can stop managing them with the [Update Management](overview.md) feature. To stop managing them, you will edit the saved search query `MicrosoftDefaultComputerGroup` in your Log Analytics workspace that is linked to your Automation account.
1212

1313
## Sign into the Azure portal
1414

1515
Sign in to the [Azure portal](https://portal.azure.com).
1616

17-
## To remove your VMs
17+
## To remove your machines
1818

1919
1. In the Azure portal, launch **Cloud Shell** from the top navigation of the Azure portal. If you are unfamiliar with Azure Cloud Shell, see [Overview of Azure Cloud Shell](../../cloud-shell/overview.md).
2020

21-
2. Use the following command to identify the UUID of a machine that you want to remove from management.
21+
2. Use the following method to identify the UUID of an Azure virtual machine or non-Azure machine that you want to remove from management.
2222

23-
```azurecli
24-
az vm show -g MyResourceGroup -n MyVm -d
25-
```
23+
# [Azure VM](#tab/azure-vm)
24+
25+
```azurecli
26+
az vm show -g MyResourceGroup -n MyVm -d
27+
```
28+
29+
# [Non-Azure machine](#tab/non-azure-machine)
30+
31+
```kusto
32+
Heartbeat
33+
| where TimeGenerated > ago(30d)
34+
| where ResourceType == "machines" and (ComputerEnvironment == "Non-Azure")
35+
| summarize by Computer, VMUUID
36+
```
37+
38+
---
2639

2740
3. In the Azure portal, navigate to **Log Analytics workspaces**. Select your workspace from the list.
2841

@@ -32,7 +45,7 @@ Sign in to the [Azure portal](https://portal.azure.com).
3245

3346
6. From the table, click the icon **Run query** to the right of the item **MicrosoftDefaultComputerGroup** with the **Legacy category** value **Updates**.
3447

35-
7. In the query editor, review the query and find the UUID for the VM. Remove the UUID for the VM and repeat the steps for any other VMs you want to remove.
48+
7. In the query editor, review the query and find the UUID for the machine. Remove the UUID for the machine and repeat the steps for any other machines you want to remove.
3649

3750
> [!NOTE]
3851
> For added protection, before making edits be sure to make a copy of the query. Then you can restore it if a problem occurs.
@@ -56,4 +69,4 @@ Sign in to the [Azure portal](https://portal.azure.com).
5669
5770
## Next steps
5871

59-
To re-enable managing your virtual machine, see [Enable Update Management by browsing the Azure portal](enable-from-portal.md) or [Enable Update Management from an Azure VM](enable-from-vm.md).
72+
To re-enable managing your Azure or non-Azure machine, see [Enable Update Management by browsing the Azure portal](enable-from-portal.md) or [Enable Update Management from an Azure VM](enable-from-vm.md).

0 commit comments

Comments
 (0)