Listing and exporting repeating SCOM alerts
As an SCOM administrator, you will be asked to provide a list of the top repeating alerts. The following example lists and exports the top 20 repeating alerts to a text file. We can change the count of 20 to a custom number by just changing the count in the following code:
$AllAlerts = Get-SCOMAlert $RepeatAlert = $AllAlerts | Sort -desc RepeatCount | Select-Object –First 20 Name, RepeatCount, MonitoringObjectPath, Description $RepeatAlert | Out-File –FilePath "C:\SCOM\MP\RepeatAlerts.txt"