In this blog post, I will share a possible solution for a problem that I encountered in my work. However, I want to make it clear that this solution is not officially supported by Microsoft, and it may have some risks or side effects that I am not aware of. Therefore, use this solution at your own discretion and responsibility.

Do you want to monitor a service on two servers and get an alert if it fails on both? In this article, I will explain how I did it using a custom management pack and a dynamic application. I will also provide the link to the management pack and the instructions on how to modify it for your own service.

– Created a service Monitor based on the following solution.


– Now created DA and added only object for the class “Custom.MultipleService.Enabled.Class”.

– Now went to Discovered Inventory in Monitoring and select the class “Dual Service Monitoring”.

– Open Health explorer and expand the parent Monitor “Availability” and select “Component Group Health Roll-up for type Object” and open properties.

– Now go to “Health Rollup Policy” and Select “Worst state of the specified percentage of members in good health” policy and select 1.

– Now create an overrides to enable alerting as well.

– Now I could see alerting is working as per my requirement.

– I have shared the management pack in the below link and you need to change the following inside the management pack.


Action to be taken in your case:

1. Change the WMI query for the services customer wants to Monitor.

Line No: 126, 350

$Services = Get-WmiObject -Query "Select * from WIn32_Service Where (name like 'Audiosrv')"

For Multiple services, you can use below.

$Services = Get-WmiObject -Query "Select * from WIn32_Service Where (name like 'OMSDK' or name like 'CSHOST' or name like 'HealthService')"

2. Now run the following PowerShell query and get the IDs you want to add in the DA.

Get-SCOMClass -Name Custom.MultipleService.Enabled.Class | Get-SCOMClassInstance | Select FullName, ID

3. Once you got the IDs, replace the IDs inside the MP, starting Line No: 432. Do not remove the Curly brackets.


4. Now save the MP and import it.