I created alert rule in log analytics,and then i exported template to create another alert rule automatically
I need to create alert rule automatically exactly same as manually created alert rule
I am able to create alert rule with the exported template,but the alert rule condition which is created by template is different from alert rule which is created manually in the portal
as shown in below diagrams:
Let me know if any additional information required
Thanks in advance
The screenshots in your question are of the alert Condition names
, Azure derives these from the properties of the alert condition. The Condition names
can't be set explicitly when creating an alert in the Azure Portal or via an ARM template. Unfortunately it seems that Azure Resource Manager produces slightly inconsistent Condition names
depending on whether the alert is created in the Azure Portal or via an ARM template.
As long as the ARM template wasn't modified you should see that the alert condition properties are the same, you can inspect these by clicking on the Whenever the average custom log search is greater than or equal to 1
or Whenever the Count of the Custom log search is greater than or equal to 1
links, that should bring up the Configure signal logic
blade.