Skip to content

Commit 2af9fef

Browse files
authored
Merge pull request #283263 from kainawroth/kainawroth-agent
AMA on Windows VM -- Removing single quotes from command
2 parents e077d66 + dae08ca commit 2af9fef

File tree

1 file changed

+27
-24
lines changed

1 file changed

+27
-24
lines changed

articles/azure-monitor/agents/azure-monitor-agent-troubleshoot-windows-vm.md

Lines changed: 27 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -12,41 +12,43 @@ ms.reviewer: jeffwo
1212
[!INCLUDE [azure-monitor-agent-architecture](../../../includes/azure-monitor-agent/azure-monitor-agent-architecture-include.md)]
1313

1414
## Basic troubleshooting steps (installation, agent not running, configuration issues)
15+
1516
Follow the steps below to troubleshoot the latest version of the Azure Monitor agent running on your Windows virtual machine:
1617

17-
1. **Carefully review the [prerequisites here](./azure-monitor-agent-manage.md#prerequisites).**
18+
1. **Carefully review the [prerequisites here](./azure-monitor-agent-manage.md#prerequisites).**
1819

19-
2. **Verify that the extension was successfully installed and provisioned, which installs the agent binaries on your machine**:
20-
1. Open Azure portal > select your virtual machine > Open **Settings** : **Extensions + applications** from the pane on the left > 'AzureMonitorWindowsAgent'should show up with Status: 'Provisioning succeeded'
21-
2. If not, check if machine can reach Azure and find the extension to install using the command below:
20+
2. **Verify that the extension was successfully installed and provisioned, which installs the agent binaries on your machine**:
21+
1. Open Azure portal > select your virtual machine > Open **Settings** : **Extensions + applications** from the pane on the left > 'AzureMonitorWindowsAgent'should show up with Status: 'Provisioning succeeded'
22+
2. If not, check if machine can reach Azure and find the extension to install using the command below:
2223
```azurecli
2324
az vm extension image list-versions --location <machine-region> --name AzureMonitorWindowsAgent --publisher Microsoft.Azure.Monitor
2425
```
25-
3. Wait for 10-15 minutes as extension maybe in transitioning status. If it still doesn't show up, [uninstall and install the extension](./azure-monitor-agent-manage.md) again and repeat the verification to see the extension show up.
26-
4. If not, check if you see any errors in extension logs located at `C:\WindowsAzure\Logs\Plugins\Microsoft.Azure.Monitor.AzureMonitorWindowsAgent` on your machine
27-
28-
3. **Verify that the agent is running**:
26+
3. Wait for 10-15 minutes as extension maybe in transitioning status. If it still doesn't show up, [uninstall and install the extension](./azure-monitor-agent-manage.md) again and repeat the verification to see the extension show up.
27+
4. If not, check if you see any errors in extension logs located at `C:\WindowsAzure\Logs\Plugins\Microsoft.Azure.Monitor.AzureMonitorWindowsAgent` on your machine
28+
29+
3. **Verify that the agent is running**:
2930
1. Check if the agent is emitting heartbeat logs to Log Analytics workspace using the query below. Skip if 'Custom Metrics' is the only destination in the DCR:
30-
```Kusto
31-
Heartbeat | where Category == "Azure Monitor Agent" and 'Computer' == "<computer-name>" | take 10
31+
```kusto
32+
Heartbeat | where Category == "Azure Monitor Agent" and Computer == "<computer-name>" | take 10
3233
```
33-
2. If not, open Task Manager and check if 'MonAgentCore.exe' process is running. If it is, wait for 5 minutes for heartbeat to show up.
34-
3. If not, check if you see any errors in core agent logs located at `C:\WindowsAzure\Resources\AMADataStore.<virtual-machine-name>\Configuration` on your machine
35-
36-
4. **Verify that the DCR exists and is associated with the virtual machine:**
37-
1. If using Log Analytics workspace as destination, verify that DCR exists in the same physical region as the Log Analytics workspace.
34+
2. If not, open Task Manager and check if 'MonAgentCore.exe' process is running. If it is, wait for 5 minutes for heartbeat to show up.
35+
3. If not, check if you see any errors in core agent logs located at `C:\WindowsAzure\Resources\AMADataStore.<virtual-machine-name>\Configuration` on your machine
36+
37+
4. **Verify that the DCR exists and is associated with the virtual machine:**
38+
1. If using Log Analytics workspace as destination, verify that DCR exists in the same physical region as the Log Analytics workspace.
3839
2. On your virtual machine, verify the existence of the file `C:\WindowsAzure\Resources\AMADataStore.<virtual-machine-name>\mcs\mcsconfig.latest.xml`. If this file doesn't exist:
39-
- The virtual machine may not be associated with a DCR. See step 3
40-
- The virtual machine may not have Managed Identity enabled. [See here](../../active-directory/managed-identities-azure-resources/qs-configure-portal-windows-vm.md#enable-system-assigned-managed-identity-during-creation-of-a-vm) on how to enable.
41-
- IMDS service isn't running/accessible from the virtual machine. [Check if you can access IMDS from the machine](../../virtual-machines/windows/instance-metadata-service.md?tabs=windows).
42-
- AMA can't access IMDS. Check if you see IMDS errors in `C:\WindowsAzure\Resources\AMADataStore.<virtual-machine-name>\Tables\MAEventTable.tsf` file.
43-
3. Open Azure portal > select your data collection rule > Open **Configuration** : **Resources** from the pane on the left > You should see the virtual machine listed here
40+
* The virtual machine may not be associated with a DCR. See step 3
41+
* The virtual machine may not have Managed Identity enabled. [See here](../../active-directory/managed-identities-azure-resources/qs-configure-portal-windows-vm.md#enable-system-assigned-managed-identity-during-creation-of-a-vm) on how to enable.
42+
* IMDS service isn't running/accessible from the virtual machine. [Check if you can access IMDS from the machine](../../virtual-machines/windows/instance-metadata-service.md?tabs=windows).
43+
* AMA can't access IMDS. Check if you see IMDS errors in `C:\WindowsAzure\Resources\AMADataStore.<virtual-machine-name>\Tables\MAEventTable.tsf` file.
44+
3. Open Azure portal > select your data collection rule > Open **Configuration** : **Resources** from the pane on the left > You should see the virtual machine listed here
4445
4. If not listed, click 'Add' and select your virtual machine from the resource picker. Repeat across all DCRs.
4546
46-
5. **Verify that agent was able to download the associated DCR(s) from AMCS service:**
47-
1. Check if you see the latest DCR downloaded at this location `C:\WindowsAzure\Resources\AMADataStore.<virtual-machine-name>\mcs\configchunks`
48-
47+
5. **Verify that agent was able to download the associated DCR(s) from AMCS service:**
48+
Check if you see the latest DCR downloaded at this location `C:\WindowsAzure\Resources\AMADataStore.<virtual-machine-name>\mcs\configchunks`
49+
4950
## Issues collecting Performance counters
51+
5052
1. Check that your DCR JSON contains a section for 'performanceCounters'. If not, fix your DCR. See [how to create DCR](./azure-monitor-agent-data-collection.md) or [sample DCR](./data-collection-rule-sample-agent.md).
5153
2. Check that the file `C:\WindowsAzure\Resources\AMADataStore.<virtual-machine-name>\mcs\mcsconfig.lkg.xml` exists.
5254
3. Open the file and check if it contains `CounterSet` nodes as shown in the example below:
@@ -61,8 +63,8 @@ Follow the steps below to troubleshoot the latest version of the Azure Monitor a
6163
</CounterSet>
6264
```
6365
64-
6566
### Issues using 'Custom Metrics' as destination
67+
6668
1. Carefully review the [prerequisites here](./azure-monitor-agent-manage.md#prerequisites).
6769
2. Ensure that the associated DCR is correctly authored to collect performance counters and send them to Azure Monitor metrics. You should see this section in your DCR:
6870
```json
@@ -84,6 +86,7 @@ Follow the steps below to troubleshoot the latest version of the Azure Monitor a
8486
2. Open it and look for any Level 2 errors and try to fix them.
8587
8688
## Issues collecting Windows event logs
89+
8790
1. Check that your DCR JSON contains a section for 'windowsEventLogs'. If not, fix your DCR. See [how to create DCR](./azure-monitor-agent-data-collection.md) or [sample DCR](./data-collection-rule-sample-agent.md).
8891
2. Check that the file `C:\WindowsAzure\Resources\AMADataStore.<virtual-machine-name>\mcs\mcsconfig.lkg.xml` exists.
8992
3. Open the file and check if it contains `Subscription` nodes as shown in the example below:

0 commit comments

Comments
 (0)