vSphere PowerCLI Reference

Get-AlarmAction

Synopsis

Lists the actions of the specified alarm definitions.

Syntax

Get-AlarmAction [[-AlarmDefinition] <AlarmDefinition[]>] [-ActionType <ActionType[]>] [-Server <VIServer[]>] [<CommonParameters>]

Related Commands

Online version
Get-AlarmActionTrigger
Get-AlarmDefinition
New-AlarmAction
New-AlarmActionTrigger
Remove-AlarmAction

Detailed Description

Lists the actions of the specified alarm definitions.

Parameters

NameTypeDescriptionRequired?Pipeline InputDefault Value
AlarmDefinitionAlarmDefinition[]Specify the alarm definitions for which you want to retrieve the configured actions.falsetrue (ByValue)
ActionTypeActionType[]Specify the type of the alarm actions you want to retrieve. The valid values are SendEmail, ExecuteScript, and Send SNMP.falsefalse
ServerVIServer[]Specify the vSphere servers on which you want to run the cmdlet. If no value is given to this parameter, the command runs on the default servers. For more information about default servers, see the description of Connect-VIServer.falsefalse

Return Type

AlarmAction

Notes

Examples

-------------- Example 1 --------------

Get-AlarmDefinition -Name "Host processor status" | Get-AlarmAction -ActionType "ExecuteScript", "SendSNMP", "SendEmail"

Extract all PowerCLI supported alarm actions for the default alarm "Host processor status".

-------------- Example 2 --------------

Get-AlarmAction -AlarmDefinition "Host processor status" -ActionType "SendSNMP" -Server 'server IP'

Extract the alarm actions for the default alarm "Host processor status" by specifying the alarm by name.


Copyright © 1998 - 2012 VMware, Inc. All rights reserved.