This monitor tracks the need to restart a Windows service due to a change in monitoring settings for this Windows service running on the server.
This monitor tracks the need to restart a Windows service due to a change in Application Performance Monitoring (APM) settings. This monitor will transition to an unhealthy state when the given service must be restarted. If the service is using the Microsoft .NET Framework, when the service is restarted, monitoring will start and the state will be reset to healthy.
When application monitoring settings are modified for a Windows service using the .NET Application Performance Monitoring template, the service targeted for monitoring might need to be restarted for the new settings to take effect. If the service is using the Microsoft .NET Framework, when the service is restarted, monitoring will start and the state will be reset to healthy. If the selected service is not using the Microsoft .NET Framework, monitoring will not start, and this monitor will remain in an unhealthy state. Only services that are written in the .NET Framework can be monitored by Application Performance Monitoring (APM). Make sure that the service that you want to monitor was written using the .NET Framework.
If the service is using the Microsoft .NET Framework, you can restart the service by clicking the following link: Restart Service
You can also stop and start the Windows service directly on the agent.
If the service is not using the Microsoft .NET Framework, you must disable it from monitoring because the .NET Application Performance Monitoring template only supports monitoring Windows services written using the Microsoft .NET Framework.
Target | Microsoft.SystemCenter.Apm.NTServiceInstance | ||
Parent Monitor | System.Health.ConfigurationState | ||
Category | ConfigurationHealth | ||
Enabled | True | ||
Alert Generate | True | ||
Alert Severity | Warning | ||
Alert Priority | Normal | ||
Alert Auto Resolve | True | ||
Monitor Type | Microsoft.Windows.2SingleEventLog2StateMonitorType | ||
Remotable | False | ||
Accessibility | Public | ||
Alert Message |
| ||
RunAs | Default |
<UnitMonitor ID="Microsoft.SystemCenter.Apm.NTServiceInstance.Restart.Monitor" Accessibility="Public" Enabled="true" Target="Microsoft.SystemCenter.Apm.NTServiceInstance" ParentMonitorID="Health!System.Health.ConfigurationState" Remotable="false" Priority="Normal" TypeID="Windows!Microsoft.Windows.2SingleEventLog2StateMonitorType" ConfirmDelivery="false">
<Category>ConfigurationHealth</Category>
<AlertSettings AlertMessage="Microsoft.SystemCenter.Apm.NTServiceInstance.Restart.Monitor.AlertMessageResourceID">
<AlertOnState>Warning</AlertOnState>
<AutoResolve>true</AutoResolve>
<AlertPriority>Normal</AlertPriority>
<AlertSeverity>Warning</AlertSeverity>
<AlertParameters>
<AlertParameter1>$Target/Host/Host/Property[Type="Windows!Microsoft.Windows.Computer"]/PrincipalName$</AlertParameter1>
<AlertParameter2>$Target/Property[Type="AL!Microsoft.SystemCenter.Apm.ApplicationInstanceBase"]/ApplicationName$</AlertParameter2>
</AlertParameters>
</AlertSettings>
<OperationalStates>
<OperationalState ID="Success" MonitorTypeStateID="SecondEventRaised" HealthState="Success"/>
<OperationalState ID="Warning" MonitorTypeStateID="FirstEventRaised" HealthState="Warning"/>
</OperationalStates>
<Configuration>
<FirstComputerName>$Target/Host/Host/Property[Type="Windows!Microsoft.Windows.Computer"]/NetworkName$</FirstComputerName>
<FirstLogName>Operations Manager</FirstLogName>
<FirstExpression>
<And>
<Expression>
<Or>
<Expression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="Integer">EventDisplayNumber</XPathQuery>
</ValueExpression>
<Operator>Equal</Operator>
<ValueExpression>
<Value Type="Integer">35001</Value>
</ValueExpression>
</SimpleExpression>
</Expression>
<Expression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="Integer">EventDisplayNumber</XPathQuery>
</ValueExpression>
<Operator>Equal</Operator>
<ValueExpression>
<Value Type="Integer">35002</Value>
</ValueExpression>
</SimpleExpression>
</Expression>
</Or>
</Expression>
<Expression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="String">PublisherName</XPathQuery>
</ValueExpression>
<Operator>Equal</Operator>
<ValueExpression>
<Value Type="String">.NET app monitoring</Value>
</ValueExpression>
</SimpleExpression>
</Expression>
<Expression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="String">Params/Param[1]</XPathQuery>
</ValueExpression>
<Operator>Equal</Operator>
<ValueExpression>
<Value Type="String">$Target/Property[Type="AL!Microsoft.SystemCenter.Apm.ApplicationInstanceBase"]/ApplicationName$</Value>
</ValueExpression>
</SimpleExpression>
</Expression>
</And>
</FirstExpression>
<SecondComputerName>$Target/Host/Host/Property[Type="Windows!Microsoft.Windows.Computer"]/NetworkName$</SecondComputerName>
<SecondLogName>Operations Manager</SecondLogName>
<SecondExpression>
<And>
<Expression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="Integer">EventDisplayNumber</XPathQuery>
</ValueExpression>
<Operator>Equal</Operator>
<ValueExpression>
<Value Type="Integer">4003</Value>
</ValueExpression>
</SimpleExpression>
</Expression>
<Expression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="String">PublisherName</XPathQuery>
</ValueExpression>
<Operator>Equal</Operator>
<ValueExpression>
<Value Type="String">Apm Agent</Value>
</ValueExpression>
</SimpleExpression>
</Expression>
<Expression>
<RegExExpression>
<ValueExpression>
<XPathQuery Type="String">EventDescription</XPathQuery>
</ValueExpression>
<Operator>ContainsSubstring</Operator>
<Pattern>$Target/Property[Type="AL!Microsoft.SystemCenter.Apm.ApplicationInstanceBase"]/ApplicationName$</Pattern>
</RegExExpression>
</Expression>
</And>
</SecondExpression>
</Configuration>
</UnitMonitor>