OmsAgentForLinux in Transitioning status

Daniel Sotreanu 85 Reputation points
2023-06-27T13:12:42.7366667+00:00

Hello,

I am not able to remove a virtual machine extension (OmsAgentForLinux), as it is already marked for deletion (Transitioning).

The error I see in the Portal is:

Status message[ExtensionOperationError] Non-zero exit code: 1, /var/lib/waagent/Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux-1.13.40/omsagent_shim.sh -disable [stdout] 2023/06/27 11:45:16 [Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux-1.13.40] Disable,error,1,Disable Failed [stderr]

I already tried to remove it from the VM OS level, Portal, PowerShell or CLI... but no luck.

Any ideas?

Thanks!

Azure Virtual Machines
Azure Virtual Machines
An Azure service that is used to provision Windows and Linux virtual machines.
8,275 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. deherman-MSFT 37,841 Reputation points Microsoft Employee
    2023-06-27T16:45:00.1266667+00:00

    @Daniel Sotreanu

    I understand you are trying to remove the OmsAgentForLinux. You have tried doing so from the portal as well as other methods but still unable to.

    You can try to use the purge method to remove the extension.

    enter image description here

    If that doesn't work you might try this option, Issue: You're unable to uninstall omsagent using the purge option.

    Let me know if that doesn't work and we can troubleshoot with you directly.


    If you still have questions, please let us know in the "comments" and we would be happy to help you. Comment is the fastest way of notifying the experts.

    If the answer has been helpful, we appreciate hearing from you and would love to help others who may have the same question. Accepting answers helps increase visibility of this question for other members of the Microsoft Q&A community.

    Thank you for helping to improve Microsoft Q&A!

    User's image


  2. Daniel Sotreanu 85 Reputation points
    2023-07-11T06:39:09.13+00:00

    In the end, following the error message in the Portal, I noticed "/var/lib/waagent/Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux-1.13.40" was missing in the VM.

    Copied over the folder from another VM and I was able to run "omsagent_shim.sh -disable" from within the VM.

    I could then remove the extension from the Portal.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.