Forum Discussion
Proxy Settings when using OMS Agent VM Extension via ARM template
Hi,
Adding the OMS agent generally we use this like below.
Adding the proxyUri to the settings. I think that should work.
{
"type": "Microsoft.Compute/virtualMachines/extensions",
"name": "[concat(parameters('vmName'),'/','MMAAgent')]",
"apiVersion": "2015-05-01-preview",
"location": "[resourceGroup().location]",
"properties": {
"publisher": "Microsoft.EnterpriseCloud.Monitoring",
"type": "MicrosoftMonitoringAgent",
"typeHandlerVersion": "1.0",
"autoUpgradeMinorVersion": true,
"settings": {
"workspaceId": "[reference(resourceId(parameters('OMSResourceGroupName'),'Microsoft.OperationalInsights/workspaces/', parameters('workspaceName')), '2015-03-20').customerId]",
"proxyUri": "[parameters('ProxyUri')]"
},
"protectedSettings": {
"workspaceKey": "[listKeys(resourceId(parameters('OMSResourceGroupName'),'Microsoft.OperationalInsights/workspaces/', parameters('workspaceName')), '2015-03-20').primarySharedKey]"
}
}
}
Vinoth_Azure It's really cool to get the proxyUri settings in ARM. It works for me on Windows but when I try it with linux version (type = "OmsAgentForLinux") it always fail with this error. Do you know if this parameter is supported on Linux version of the Microsoft.EnterpriseCloud.Monitoring extension?
"code": "VMExtensionProvisioningError",
"message": "VM has reported a failure when processing extension 'LogAnalytics-Agent-Extension'. Error message:
\"Enable failed with exit code 53 Installation failed due to incorrect workspace key. Please check if the workspace
key is correct. For details, check logs in
/var/log/azure/Microsoft.EnterpriseCloud.Monitoring.OmsAgentForLinux/extension.log\"\r\n\r\nMore information on
troubleshooting is available at https://aka.ms/VMExtensionOMSAgentLinuxTroubleshoot "
- muhammadshameemJun 29, 2022Copper Contributor
Steeve_Roy I'm still getting the same error , any work around for linux vm