HealthDefinition Element

 

Updated: October 9, 2012

Applies To: Windows Server 2012 Essentials, Windows Home Server 2011, Windows Storage Server 2008 R2 Essentials, Windows Small Business Server 2011 Essentials

Specifies alerts, health states, and repairs for the health add-in.

  
<xs:element name="HealthDefinition" type="HealthDefinitionElement" maxOccurs="unbounded" minOccurs="0" />  
  
<xs:complexType name="HealthDefinitionElement">  
  <xs:sequence>  
    <xs:element name="Filter" maxOccurs="1" minOccurs="0">...</xs:element>  
    <xs:element name="Condition" maxOccurs="1" minOccurs="0">...</xs:element>  
    <xs:element name="HealthStatusChange">...</xs:element>  
    <xs:element name="AlertAction" maxOccurs="1" minOccurs="0">...</xs:element>  
    <xs:element name="Troubleshoot" type="TroubleshootElement" minOccurs="0"/>  
    <xs:element name="RepairAction" maxOccurs="1" minOccurs="0">...</xs:element>  
  </xs:sequence>  
  <xs:attribute name="Name" type="xs:ID" use="required" />  
  <xs:attribute name="Title" type="xs:string" use="required" />  
</xs:complexType>  

The following sections describe attributes, child elements, and parent elements.

Attributes

AttributeDescription
NameRequired ID attribute.

Specifies the name of the health definition. The name must be unique among all of the health definitions of the feature.
TitleRequired string attribute

Specifies the title of the health definition.

Child Elements

ElementDescription
Filter Element (HealthDefinition)Specifies whether the health definition is applicable to the current version of the operating system.
Condition ElementSpecifies a PowerShell script (using the PowerShell element) or a managed assembly (using the Binary element) that checks the condition of a component. The managed assembly must implement the IBinaryAction interface.
HealthStatusChange ElementSpecifies the health state of the system. The health state can be one of the following values: OK, Information, Warning, or Critical.
AlertAction ElementSpecifies the notification action that is performed when the specified condition occurs. The action can be a PowerShell script or a managed assembly.
Troubleshoot ElementSpecifies information that can be used to attempt to manually resolve the problem.
RepairAction ElementSpecifies the action that is performed to fix a problem.

Parent Elements

ElementDescription
HealthDefinitions ElementRepresents the notifications and actions that are used to report and repair issues with operating system features.

How to: Create a Definition XML File

Community Additions

ADD
Show: