# Managed Object - AlarmManager(vim.alarm.AlarmManager)

Property of
  ServiceContent
See also
  Alarm, AlarmDescription, AlarmExpression, AlarmFilterSpec, AlarmSpec, AlarmState, ManagedEntity
Since
  2.0

## Managed Object Description

The alarm manager is a singleton object for managing alarms within a service instance.

Properties

Name | Type | Description
--- | --- | ---
defaultExpression* P | AlarmExpression[] | The default setting for each alarm expression, used to populate the initial client wizard screen.
description P | AlarmDescription | The static descriptive strings used in alarms.

*May not be presentP Required privilege: System.View

Methods

Methods defined in this Managed Object
AcknowledgeAlarm, AreAlarmActionsEnabled, ClearTriggeredAlarms, CreateAlarm, DisableAlarm, EnableAlarm, EnableAlarmActions, GetAlarm, GetAlarmState

# AcknowledgeAlarm(acknowledgeAlarm)

Acknowledge the alarm on a managed entity. The actions associated with the alarm will not fire until the alarm's next distinct occurrence; that is, until after the alarm has entered the green or gray states at least once. Calling this method on an acknowledged or non-triggered alarm.

Required Privileges
  None
Since
  vSphere API 4.0

Parameters

Name | Type | Description
--- | --- | ---
_this | ManagedObjectReference | A reference to the AlarmManager used to make the method call.
alarm P | ManagedObjectReference to a Alarm | The Alarm to acknowledge. Since vSphere API 4.0
entity P | ManagedObjectReference to a ManagedEntity | The ManagedEntity for which to acknowledge the Alarm. Since vSphere API 4.0

PRequired privilege - see tooltip for details

Return Value

Type | Description
--- | ---
None

Faults

Type | Description
--- | ---
RuntimeFault | Thrown if any type of runtime fault is thrown that is not covered by the other faults; for example, a communication error.

Events

Type
None

Show WSDL type definition
<element xmlns="http://www.w3.org/2001/XMLSchema" xmlns:sms="urn:sms" name="AcknowledgeAlarm" type="sms:AcknowledgeAlarmRequestType"/> <element xmlns="http://www.w3.org/2001/XMLSchema" xmlns:sms="urn:sms" name="AcknowledgeAlarmResponse"> <complexType/> </element>

# AreAlarmActionsEnabled(getAlarmActionsEnabled)

Returns true if alarm actions are enabled on the specified managed entity.

Required Privileges
  None
Since
  vSphere API 4.0

Parameters

Name | Type | Description
--- | --- | ---
_this | ManagedObjectReference | A reference to the AlarmManager used to make the method call.
entity P | ManagedObjectReference to a ManagedEntity | The managed entity to look up. Since vSphere API 4.0

P Required privilege: entity

Return Value

Type | Description
--- | ---
xsd:boolean |

Faults

Type | Description
--- | ---
RuntimeFault | Thrown if any type of runtime fault is thrown that is not covered by the other faults; for example, a communication error.

Events

Type
None

Show WSDL type definition
<element xmlns="http://www.w3.org/2001/XMLSchema" xmlns:sms="urn:sms" name="AreAlarmActionsEnabled" type="sms:AreAlarmActionsEnabledRequestType"/> <element xmlns="http://www.w3.org/2001/XMLSchema" xmlns:sms="urn:sms" name="AreAlarmActionsEnabledResponse"> <complexType> <sequence> <element name="returnval" type="xsd:boolean"/> </sequence> </complexType> </element>

# ClearTriggeredAlarms(clearTriggeredAlarms)

Resets all triggered alarms to green. Should be used when mass alarm reset is needed.

Required Privileges
  Alarm.SetStatus
Since
  vSphere API 6.7

Parameters

Name | Type | Description
--- | --- | ---
_this | ManagedObjectReference | A reference to the AlarmManager used to make the method call.
filter P | AlarmFilterSpec | Since vSphere API 6.7

P Required privilege: filter

Return Value

Type | Description
--- | ---
None

Faults

Type | Description
--- | ---
RuntimeFault | Thrown if any type of runtime fault is thrown that is not covered by the other faults; for example, a communication error.

Events

Type
None

Show WSDL type definition
<element xmlns="http://www.w3.org/2001/XMLSchema" xmlns:sms="urn:sms" name="ClearTriggeredAlarms" type="sms:ClearTriggeredAlarmsRequestType"/> <element xmlns="http://www.w3.org/2001/XMLSchema" xmlns:sms="urn:sms" name="ClearTriggeredAlarmsResponse"> <complexType/> </element>

# CreateAlarm(create)

Creates an alarm.

In addition to the Alarm.Create privilege, may also require the Global.ScriptAction if a RunScriptAction action is specified in the AlarmSpec.

Required Privileges
  None

Parameters

Name | Type | Description
--- | --- | ---
_this | ManagedObjectReference | A reference to the AlarmManager used to make the method call.
entity P | ManagedObjectReference to a ManagedEntity | The entity with which the alarm is associated. Since 2.0
spec P | AlarmSpec | The specification for the new alarm. Since 2.0

PRequired privilege - see tooltip for details

Return Value

Type | Description
--- | ---
ManagedObjectReference to a Alarm | A reference to the Alarm object created by the operation.

Faults

Type | Description
--- | ---
DuplicateName | Thrown if an alarm with the name already exists.
InvalidName | Thrown if the alarm name is empty or too long.
RuntimeFault | Thrown if any type of runtime fault is thrown that is not covered by the other faults; for example, a communication error.

Events

Type
None

Show WSDL type definition
<element xmlns="http://www.w3.org/2001/XMLSchema" xmlns:sms="urn:sms" name="CreateAlarm" type="sms:CreateAlarmRequestType"/> <element xmlns="http://www.w3.org/2001/XMLSchema" xmlns:sms="urn:sms" name="CreateAlarmResponse"> <complexType> <sequence> <element name="returnval" type="sms:ManagedObjectReference"/> </sequence> </complexType> </element>

# DisableAlarm(disableAlarm)

Disables alarm for a specific entity.

Required Privileges
  None
Since
  vSphere API 6.9.1

Parameters

Name | Type | Description
--- | --- | ---
_this | ManagedObjectReference | A reference to the AlarmManager used to make the method call.
alarm P | ManagedObjectReference to a Alarm | The Alarm being disabled. Since vSphere API 6.9.1
entity P | ManagedObjectReference to a ManagedEntity | The ManagedEntity on which to disable the alarm. Since vSphere API 6.9.1

PRequired privilege - see tooltip for details

Return Value

Type | Description
--- | ---
None

Faults

Type | Description
--- | ---
RuntimeFault | Thrown if any type of runtime fault is thrown that is not covered by the other faults; for example, a communication error.

Events

Type
None

Show WSDL type definition
<element xmlns="http://www.w3.org/2001/XMLSchema" xmlns:sms="urn:sms" name="DisableAlarm" type="sms:DisableAlarmRequestType"/> <element xmlns="http://www.w3.org/2001/XMLSchema" xmlns:sms="urn:sms" name="DisableAlarmResponse"> <complexType/> </element>

# EnableAlarm(enableAlarm)

Enables alarm for a specific entity.

Required Privileges
  None
Since
  vSphere API 6.9.1

Parameters

Name | Type | Description
--- | --- | ---
_this | ManagedObjectReference | A reference to the AlarmManager used to make the method call.
alarm P | ManagedObjectReference to a Alarm | The Alarm being enabled. Since vSphere API 6.9.1
entity P | ManagedObjectReference to a ManagedEntity | The ManagedEntity on which to enable the alarm. Since vSphere API 6.9.1

PRequired privilege - see tooltip for details

Return Value

Type | Description
--- | ---
None

Faults

Type | Description
--- | ---
RuntimeFault | Thrown if any type of runtime fault is thrown that is not covered by the other faults; for example, a communication error.

Events

Type
None

Show WSDL type definition
<element xmlns="http://www.w3.org/2001/XMLSchema" xmlns:sms="urn:sms" name="EnableAlarm" type="sms:EnableAlarmRequestType"/> <element xmlns="http://www.w3.org/2001/XMLSchema" xmlns:sms="urn:sms" name="EnableAlarmResponse"> <complexType/> </element>

# EnableAlarmActions(setAlarmActionsEnabled)

Enables or disables alarms on the specified managed entity.

Required Privileges
  None
Since
  vSphere API 4.0

Parameters

Name | Type | Description
--- | --- | ---
_this | ManagedObjectReference | A reference to the AlarmManager used to make the method call.
entity P | ManagedObjectReference to a ManagedEntity | The managed entity on which to set a schedule. Since vSphere API 4.0
enabled P | xsd:boolean | true, if alarms are enabled during the schedule. Since vSphere API 4.0

PRequired privilege - see tooltip for details

Return Value

Type | Description
--- | ---
None

Faults

Type | Description
--- | ---
RuntimeFault | Thrown if any type of runtime fault is thrown that is not covered by the other faults; for example, a communication error.

Events

Type
None

Show WSDL type definition
<element xmlns="http://www.w3.org/2001/XMLSchema" xmlns:sms="urn:sms" name="EnableAlarmActions" type="sms:EnableAlarmActionsRequestType"/> <element xmlns="http://www.w3.org/2001/XMLSchema" xmlns:sms="urn:sms" name="EnableAlarmActionsResponse"> <complexType/> </element>

# GetAlarm(getAlarm)

Available alarms defined on the entity. These alarms do not include any inherited alarms; that is, alarms associated with parent entities.

Required Privileges
  System.View

Parameters

Name | Type | Description
--- | --- | ---
_this | ManagedObjectReference | A reference to the AlarmManager used to make the method call.
entity* P | ManagedObjectReference to a ManagedEntity | The entity. If not set, alarms are returned for all visible entities. Since 2.0

*Need not be set P Required privilege: entity

Return Value

Type | Description
--- | ---
ManagedObjectReference[] to a Alarm[] | A reference to the Alarm objects returned by the operation.

Faults

Type | Description
--- | ---
RuntimeFault | Thrown if any type of runtime fault is thrown that is not covered by the other faults; for example, a communication error.

Events

Type
None

Show WSDL type definition
<element xmlns="http://www.w3.org/2001/XMLSchema" xmlns:sms="urn:sms" name="GetAlarm" type="sms:GetAlarmRequestType"/> <element xmlns="http://www.w3.org/2001/XMLSchema" xmlns:sms="urn:sms" name="GetAlarmResponse"> <complexType> <sequence> <element name="returnval" type="sms:ManagedObjectReference" minOccurs="0" maxOccurs="unbounded"/> </sequence> </complexType> </element>

# GetAlarmState(getAlarmState)

The state of instantiated alarms on the entity.

Required Privileges
  None

Parameters

Name | Type | Description
--- | --- | ---
_this | ManagedObjectReference | A reference to the AlarmManager used to make the method call.
entity P | ManagedObjectReference to a ManagedEntity | The entity. Since 2.0

P Required privilege: entity

Return Value

Type | Description
--- | ---
AlarmState[] | The state of instantiated alarms.

Faults

Type | Description
--- | ---
RuntimeFault | Thrown if any type of runtime fault is thrown that is not covered by the other faults; for example, a communication error.

Events

Type
None

Show WSDL type definition
<element xmlns="http://www.w3.org/2001/XMLSchema" xmlns:sms="urn:sms" name="GetAlarmState" type="sms:GetAlarmStateRequestType"/> <element xmlns="http://www.w3.org/2001/XMLSchema" xmlns:sms="urn:sms" name="GetAlarmStateResponse"> <complexType> <sequence> <element name="returnval" type="sms:AlarmState" minOccurs="0" maxOccurs="unbounded"/> </sequence> </complexType> </element>