다음을 통해 공유


OperationalState

Applies To: Operations Manager 2007 R2, System Center Operations Manager 2007

Defines a mapping between a health state and a monitor type state.

Schema Hierarchy

ManagementPack
  Monitoring
    Monitors
      UnitMonitor
        OperationalStates
          OperationalState

Syntax

<OperationalState ID=”OperationalStateID” Comment=”Comment” MonitorTypeStateID=”MonitorTypeStateID” HealthState=””/>

Attributes and Elements

The following sections describe attributes, child elements, and the parent element of the OperationalState element.

Attributes

Attribute Description

ID

Required attribute. Represents the identity of the operational state. Must be unique within the UnitMonitor definition.

Comment

Optional attribute. Represents commentary by the management pack author.

MonitorTypeStateID

Required attribute. The monitor type state ID to map to the health state.

HealthState

Required attribute. The health state to map to the monitor type state ID.

HealthState Attribute Values

Value Description

Warning

The monitor type state reflects a warning state of the monitor.

Error

The monitor type state reflects an error state of the monitor.

Success

The monitor type state reflects a success state of the monitor.

Child Elements

None.

Parent Elements

Element Description

OperationalStates

Contains mappings between health states and the monitor type states that are defined in the monitor’s unit monitor type.

Remarks

To see a demonstration of how operational states are expressed in a unit monitor, see OperationalStates.

It is a best practice to define a DisplayString element that contains a name and description associated with the operational state. For example, consider a unit monitor that defines the following operational states:

<UnitMonitor ID="Microsoft.Windows.Client.Vista.NetworkAdapter.NetworkAdapterConnectionHealth" Accessibility="Public" Enabled="false" Target="Vista!Microsoft.Windows.Client.Vista.NetworkAdapter" ParentMonitorID="SystemHealth!System.Health.AvailabilityState" Remotable="true" Priority="Normal" TypeID="Windows!Microsoft.Windows.2SingleEventLog2StateMonitorType" ConfirmDelivery="false">
  <Category>AvailabilityHealth</Category>

  <OperationalStates>
    <OperationalState ID="Disconnected" MonitorTypeStateID="FirstEventRaised" HealthState="Error" />
    <OperationalState ID="Connected" MonitorTypeStateID="SecondEventRaised" HealthState="Success" />
  </OperationalStates>
  <Configuration>
    …
  </Configuration>
</UnitMonitor>

The display strings for each operational state would look like the following the sample. The ElementID value is the ID of the unit monitor. The SubElementID value is the ID of the operational state.

<DisplayString ElementID="Microsoft.Windows.Client.Vista.NetworkAdapter.NetworkAdapterConnectionHealth" SubElementID="Disconnected">
   <Name>Network Adapter Disconnected</Name>
   <Description>The network adapter is disconnected.</Description>
</DisplayString>

<DisplayString ElementID="Microsoft.Windows.Client.Vista.NetworkAdapter.NetworkAdapterConnectionHealth" SubElementID="Connected">
   <Name>Network Adapter Connected</Name>
   <Description>The network adapter is connected.</Description>
</DisplayString>

To see the entire unit monitor definition, see UnitMonitor. To learn how to provide localizable names and descriptions associated with an operational state, see OperationalStates.

See Also

Reference

OperationalStates