Showing results for 
Search instead for 
Did you mean: 
Create Post

Mute alerts for a group

Is it possible to mute alerts for a group?

Labels (1)
0 Kudos
8 Replies
Level 9

I also had this question.

I have attempted to achieve this task through the Orion SDK using Powershell, since there is no way to do it from the UI. This can be used as a workaround if needed...

I believe I have achieved this by using the following code:

# Load the SwisSnapin

Add-PSSnapin "SwisSnapin"

# Get Swis Connection Info

$username = Read-Host "Enter Username"

$SecurePassword = Read-Host "Enter Password"  -AsSecureString

$BSTR = [System.Runtime.InteropServices.Marshal]::SecureStringToBSTR($SecurePassword)

$Password = [System.Runtime.InteropServices.Marshal]::PtrToStringAuto($BSTR)

$OrionServer = "OrionServer"

$swis = Connect-Swis $OrionServer -UserName $Username -Password $password

# You can get the URI by using $URI = Get-SwisData $swis "SELECT URI FROM Orion.Container WHERE Name LIKE 'WhateverGroupHere'"

$URI = "Some Group's URI HERE"

# This is the line that Mutes the group for Alerts

Invoke-SwisVerb $swis -verb "SuppressAlerts" -EntityName Orion.AlertSuppression @(,@([string]$URI))

# Checking if the group is muted or not.

$MutedOrNot = Invoke-SwisVerb $swis -verb "getAlertSuppressionState" -EntityName Orion.AlertSuppression @(,@([string]$URI))

$MutedOrNot = $MutedOrNot.InnerText.Replace($URI,"")

if($MutedOrNot -match "\."){$MutedOrNot = ($MutedOrNot -replace '(\d)').Split(".")[1]}


# If you want to unmute the group for alerts, uncomment this line of code:

#Invoke-SwisVerb $swis -verb "ResumeAlerts" -EntityName Orion.AlertSuppression @(,@([string]$URI))



Can this be done for an specific group of nodes? Like reading node names from a text file.

Thanks in advance


0 Kudos

In theory you could feed node names in from a text file, pull the URI for those nodes, and put them in an array. Someone much smarter than me will have to figure that one out, though

0 Kudos

The Manage Nodes and Manage Entities pages don't currently allow you to suppress alerting by group. If you have a custom property assigned to each node in the group, you can use that to display your nodes in the Manage Nodes page and mute the alerting.

Thanks Nick!

0 Kudos

This sounds like a Feature Request to me . . .



0 Kudos

Well done rschroeder​ !

0 Kudos