且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

通过PowerShell将现有操作组附加到新的度量标准警报规则

更新时间:2023-12-02 22:18:28

似乎在这里回答了同样的问题:


https://***.com/questions/55773038/create-log-alert-rule-through-powershell-and-attach-more-than - 酮动作组


I want to create a metric alert rule and attach some existing action groups to that rule. My powershell code is showing some error like this

" Add-AzMetricAlertRule : Cannot bind parameter 'Action'. Cannot convert the    "Microsoft.Azure.Management.Monitor.Management.Models.ActivityLogAlertActionGroup" value of type 
"Microsoft.Azure.Management.Monitor.Management.Models.ActivityLogAlertActionGroup" to type "Microsoft.Azure.Management.Monitor.Management.Models.RuleAction".  "

How can I overcome this problem ? How can I associate a existing Action Group through PowerShell ?


Sourav Karmakar

Seems like the same question was answered here:

https://***.com/questions/55773038/create-log-alert-rule-through-powershell-and-attach-more-than-one-action-groups