question

IsraelSahar-7915 avatar image
0 Votes"
IsraelSahar-7915 asked PradeepKommaraju-MSFT answered

Turn off Extension without uninstalling it

Hello,
This is General Question about Azure Monitor Agent

VM system/ Extension Name:
- Windows VM - AzureMonitorWindowsAgent
- Linux VM - AzureMonitorLinuxAgent

There is a way to turn off the Agent without uninstall the Extension?
i didn't find any doc or info about that..

On the linux machine i found 2 services related to the agent but i don't know if stopping them is the right way..

Thnaks


azure-virtual-machinesazure-virtual-machines-extensionazure-virtual-machines-monitoring
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

PradeepKommaraju-MSFT avatar image
0 Votes"
PradeepKommaraju-MSFT answered

Hi @IsraelSahar-7915

Thank you for reaching out to Microsoft Q & A Platform .

Unfortunately , I don't think there is a way to disable the service ,
If we try to tweak into it and disable the service from the VM -->This operation will actually start other kinds of VM restart timeouts/issues etc .

Suggested approach is , If you don't need the service please go ahead and uninstall it .
And if you want it at a later point just re install it using :

Set-AzVMExtension -Name AMAWindows -ExtensionType AzureMonitorWindowsAgent -Publisher Microsoft.Azure.Monitor -ResourceGroupName <resource-group-name> -VMName <virtual-machine-name> -Location <location> -TypeHandlerVersion 1.0

Ref: https://docs.microsoft.com/en-us/azure/azure-monitor/agents/azure-monitor-agent-install?tabs=ARMAgentPowerShell%2CPowerShellWindows%2CPowerShellWindowsArc%2CCLIWindows%2CCLIWindowsArc#azure-virtual-machines

Hope this helps , And request you to accept the answer if it helps .

Thanks & Regards,
Pradeep

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.