Tipo di monitoraggio unità contatore prestazioni di System Center 2012 Virtual Machine Manager
Microsoft.SystemCenter.VirtualMachineManager.2012.Performance.ScriptBasedConsecutiveSamplesTwoThresholdsMonitorType (UnitMonitorType)
Questo tipo di monitoraggio consente di rilevare l'utilizzo della CPU o della memoria
Element properties:
Member Modules:
Overrideable Parameters:
Source Code:
<UnitMonitorType ID="Microsoft.SystemCenter.VirtualMachineManager.2012.Performance.ScriptBasedConsecutiveSamplesTwoThresholdsMonitorType" Accessibility="Internal">
<MonitorTypeStates>
<MonitorTypeState ID="ConditionSuccess" NoDetection="false"/>
<MonitorTypeState ID="ConditionWarn" NoDetection="false"/>
<MonitorTypeState ID="ConditionError" NoDetection="false"/>
</MonitorTypeStates>
<Configuration>
<xsd:element name="IntervalSeconds" type="xsd:integer"/>
<xsd:element name="TimeoutSeconds" type="xsd:integer"/>
<xsd:element name="WarningThreshold" type="xsd:integer"/>
<xsd:element name="CriticalThreshold" type="xsd:integer"/>
<xsd:element name="NumSamples" type="xsd:unsignedInt"/>
<xsd:element name="Arguments" type="xsd:string"/>
<xsd:element name="ScriptBody" type="xsd:string"/>
<xsd:element name="ObjectName" type="xsd:string"/>
<xsd:element name="CounterName" type="xsd:string"/>
<xsd:element name="InstanceName" type="xsd:string"/>
<xsd:element name="Value" type="xsd:string"/>
</Configuration>
<OverrideableParameters>
<OverrideableParameter ID="IntervalSeconds" Selector="$Config/IntervalSeconds$" ParameterType="int"/>
<OverrideableParameter ID="WarningThreshold" Selector="$Config/WarningThreshold$" ParameterType="int"/>
<OverrideableParameter ID="CriticalThreshold" Selector="$Config/CriticalThreshold$" ParameterType="int"/>
<OverrideableParameter ID="NumSamples" Selector="$Config/NumSamples$" ParameterType="int"/>
</OverrideableParameters>
<MonitorImplementation>
<MemberModules>
<DataSource ID="DS" TypeID="Windows!Microsoft.Windows.TimedScript.PerformanceProvider">
<IntervalSeconds>$Config/IntervalSeconds$</IntervalSeconds>
<SyncTime/>
<ScriptName>ConsecutiveSamplesTwoThresholds.vbs</ScriptName>
<Arguments>$Config/Arguments$</Arguments>
<ScriptBody><Script>$Config/ScriptBody$</Script></ScriptBody>
<TimeoutSeconds>$Config/TimeoutSeconds$</TimeoutSeconds>
<ObjectName>$Config/ObjectName$</ObjectName>
<CounterName>$Config/CounterName$</CounterName>
<InstanceName>$Config/InstanceName$</InstanceName>
<Value>$Data/Property[@Name='Utilization']$</Value>
</DataSource>
<ConditionDetection ID="SamplesCD" TypeID="SystemPerf!System.Performance.ConsecutiveSamplesCondition">
<Threshold>0</Threshold>
<Direction>greater</Direction>
</ConditionDetection>
<ConditionDetection ID="SamplesCounter" TypeID="System!System.ExpressionFilter">
<Expression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="Integer">Value</XPathQuery>
</ValueExpression>
<Operator>GreaterEqual</Operator>
<ValueExpression>
<Value Type="Integer">$Config/NumSamples$</Value>
</ValueExpression>
</SimpleExpression>
</Expression>
</ConditionDetection>
<ConditionDetection ID="HealthyCD" TypeID="System!System.ExpressionFilter">
<Expression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="Integer">/DataItem/SampleValue</XPathQuery>
</ValueExpression>
<Operator>LessEqual</Operator>
<ValueExpression>
<Value Type="Integer">$Config/WarningThreshold$</Value>
</ValueExpression>
</SimpleExpression>
</Expression>
</ConditionDetection>
<ConditionDetection ID="WarningCD" TypeID="System!System.ExpressionFilter">
<Expression>
<And>
<Expression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="Integer">/DataItem/SampleValue</XPathQuery>
</ValueExpression>
<Operator>LessEqual</Operator>
<ValueExpression>
<Value Type="Integer">$Config/CriticalThreshold$</Value>
</ValueExpression>
</SimpleExpression>
</Expression>
<Expression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="Integer">/DataItem/SampleValue</XPathQuery>
</ValueExpression>
<Operator>Greater</Operator>
<ValueExpression>
<Value Type="Integer">$Config/WarningThreshold$</Value>
</ValueExpression>
</SimpleExpression>
</Expression>
</And>
</Expression>
</ConditionDetection>
<ConditionDetection ID="ErrorCD" TypeID="System!System.ExpressionFilter">
<Expression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="Integer">/DataItem/SampleValue</XPathQuery>
</ValueExpression>
<Operator>Greater</Operator>
<ValueExpression>
<Value Type="Integer">$Config/CriticalThreshold$</Value>
</ValueExpression>
</SimpleExpression>
</Expression>
</ConditionDetection>
</MemberModules>
<RegularDetections>
<RegularDetection MonitorTypeStateID="ConditionSuccess">
<Node ID="HealthyCD">
<Node ID="SamplesCounter">
<Node ID="SamplesCD">
<Node ID="DS"/>
</Node>
</Node>
</Node>
</RegularDetection>
<RegularDetection MonitorTypeStateID="ConditionWarn">
<Node ID="WarningCD">
<Node ID="SamplesCounter">
<Node ID="SamplesCD">
<Node ID="DS"/>
</Node>
</Node>
</Node>
</RegularDetection>
<RegularDetection MonitorTypeStateID="ConditionError">
<Node ID="ErrorCD">
<Node ID="SamplesCounter">
<Node ID="SamplesCD">
<Node ID="DS"/>
</Node>
</Node>
</Node>
</RegularDetection>
</RegularDetections>
</MonitorImplementation>
</UnitMonitorType>