PowerCLI

 View Only
  • 1.  Listing of Enabled alarm definitions with sendsnmp enabled

    Posted Feb 26, 2026 12:21 PM

    I want a listing of enabled Alarm Definitions that have the snmp toggle turned on. We are moving from one monitoring tool to another and I need to find out what alarms are affected; also export to csv.

    Get-AlarmDefinition & Get-AlarmAction -ActionType SendSNMP are in play. I'm okay with the enabled and SendSNMP columns reporting both true and false (audit)

    Desired output:



    -------------------------------------------


  • 2.  RE: Listing of Enabled alarm definitions with sendsnmp enabled

    Posted Feb 28, 2026 10:58 PM

    Hi Joy, 

    I solved it for trap-enabled and mail-enabled so:

    $salarms = Get-AlarmDefinition -Name "*" | Get-AlarmAction -ActionType SendSNMP | Select AlarmDefinition, AlarmVersion, @{Name="Trigger";e={$_.Trigger -join ", "}} | ft
    $salarms
    write-host ("Amount of alarms with defined SNMP trap aktion:", $salarms.count)

    $ealarms = Get-AlarmDefinition -Name "*" | Get-AlarmAction -ActionType SendEmail | Select AlarmDefinition, To, @{Name="Trigger";e={$_.Trigger -join ", "}} | ft
    $ealarms
    write-host ("Amount of alarms with defined eMail aktion:", $ealarms.count)

    -------------------------------------------



  • 3.  RE: Listing of Enabled alarm definitions with sendsnmp enabled

    Posted Mar 02, 2026 11:03 AM

    Thank you for your reply. I'll update here when I get the code to conduct my alarm audit. 

    -------------------------------------------