none
waagent reporting "/opt/microsoft/omsagent/bin/service_control doesnot exist" same error over and over in waagent.log RRS feed

  • Question

  • My waagent.log file is currently over 800MB large. It is full of the same install or upgrade attempt and then error over and over again. How do I fix this azure service? My VM is Linux Ubuntu 14.04, Standard DS3. The error message from the log is below:

    [stderr]
    , duration=0
    2019/10/04 07:49:01.243633 INFO [Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux-1.11.15] Remove extension handler directory: /var/lib/waagent/Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux-1.11.15
    2019/10/04 07:49:01.299042 INFO ExtHandler Deleted cgroup "/sys/fs/cgroup/cpu/walinuxagent.extensions/Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux_1.11.15".
    2019/10/04 07:49:01.312848 INFO ExtHandler Deleted cgroup "/sys/fs/cgroup/memory/walinuxagent.extensions/Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux_1.11.15".
    2019/10/04 07:49:04.441908 INFO [Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux-1.11.15] Target handler state: enabled
    2019/10/04 07:49:04.451328 INFO [Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux-1.11.15] [Enable] current handler state is: notinstalled
    2019/10/04 07:49:04.451894 INFO [Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux-1.11.15] Using existing extension package: /var/lib/waagent/Microsoft.EnterpriseCloud.Monitoring__OmsAgentForLinux__1.11.15.zip
    2019/10/04 07:49:04.453877 INFO [Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux-1.11.15] Unzipping extension package: /var/lib/waagent/Microsoft.EnterpriseCloud.Monitoring__OmsAgentForLinux__1.11.15.zip
    2019/10/04 07:49:05.173787 INFO [Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux-1.11.15] Initializing extension Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux-1.11.15
    2019/10/04 07:49:05.177439 INFO ExtHandler Created cgroup /sys/fs/cgroup/cpu/walinuxagent.extensions/Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux_1.11.15
    2019/10/04 07:49:05.179702 INFO ExtHandler Created cgroup /sys/fs/cgroup/memory/walinuxagent.extensions/Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux_1.11.15
    2019/10/04 07:49:05.181906 INFO [Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux-1.11.15] Update settings file: 0.settings
    2019/10/04 07:49:05.184382 INFO [Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux-1.7.9] Disable extension [omsagent.py -disable]
    2019/10/04 07:49:05.221236 INFO ExtHandler Added PID 29580 to cgroup /sys/fs/cgroup/cpu/walinuxagent.extensions/Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux_1.7.9
    2019/10/04 07:49:05.223605 INFO ExtHandler Added PID 29580 to cgroup /sys/fs/cgroup/memory/walinuxagent.extensions/Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux_1.7.9
    2019/10/04 07:49:05 OmsAgentForLinux started to handle.
    2019/10/04 07:49:05 [Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux-1.7.9] cwd is /var/lib/waagent/Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux-1.7.9
    2019/10/04 07:49:05 [Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux-1.7.9] Change log file to /var/log/azure/Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux/1.7.9/extension.log
    2019/10/04 07:49:07.260743 ERROR ExtHandler Event: name=Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux, op=Download, message=[ExtensionError] Non-zero exit code: 1, omsagent.py -disable
    [stdout]
    2019/10/04 07:49:05 [Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux-1.7.9] Disable,failed,1,OMSAgent service control script /opt/microsoft/omsagent/bin/service_control doesnot exist. Disable cannot be called before install.

    Tuesday, October 22, 2019 2:09 PM

All replies

  • Looks like the OMS extension is failing. 

    I suggest simply removing the extension then letting it reapply itself. 

    To remove, go to the Portal -> Select your VM -> Select Extensions -> Select OMS Extension -> Remove

    Once it is removed I suggest clearing out the Waagent file to get some space back. 

    If you are having OMS installed via Azure Monitoring software it should be applied again automatically

    If not, you can manually reinstall the extension 

    https://docs.microsoft.com/en-us/azure/virtual-machines/extensions/oms-linux

    Give that a go and let me know if it helps. 

    Tuesday, October 22, 2019 4:01 PM
    Moderator
  • I tried that but it fails to remove the agent and reports:

    Failed to delete the virtual machine extension 'OmsAgentForLinux'. Error: error

    On the extensions tab for that VM the status of the OmsAgentForLinux says "Transitioning". Is there a way I can stop the oms process and then remove it?

    Thursday, October 24, 2019 5:31 PM
  • Hmmm usually it will eventually either succeed or fail then you can attempt the delete again. 

    Can you email me at AzCommunity@microsoft.com and provide me with the following: 

    - SubscriptionID

    - VM Name

    - Resource Group Name

    I can take a look at the backend and see if I can unblock you. 

    Friday, October 25, 2019 7:47 PM
    Moderator
  • Thanks I just sent you an email.
    Friday, October 25, 2019 8:39 PM
  • Any update on this? 


    Thursday, November 7, 2019 5:24 PM
    Moderator