SCOM 2016 System Center Core Monitoring Fix

Note: This is not tested with the new hotfix MP released for SCOM 2016 found here: you add the hotfix MP i recommend to also delete this one.*** Update 2 *** Fixed issue with SCOMprece

5 Star
571 times
Add to favorites
System Center
E-mail Twitter Digg Facebook
Sign in to ask a question

  • Collection script timeout
    3 Posts | Last post June 13, 2017
    • Hi,
      I have a SCOm 2016 UR3 environment with yhis MP loaded. Many servers report that Microsoft.SystemCenter.HealthService.SCOMpercentageCPUTimeCollectionAddendum workflow times out (120sec). Have you seen this in any of your environments?
    • Hi, I have not seen this myself. But if servers have a lot of processes running I can see this script taking a long time to run.
      I did some measuring of what parts of the script was taking the most time, and unfortunately to tackle this I will have to rewrite everything from scratch (removing all the original code). In my environment the script normally runs for about 30 - 40 sec. 
      To find out more about you environment specifics take the script and run it on the server where you are seeing the problem. Run it from powershell command line (admin) and not from the ISE. 
      Do : 
      .\SCOMpercentageCPUTimeCounter.ps1 -ComputerName "servername.mydomain.dom" -ConfigForRun "False" -ProcessIterationCount 3
      Usually it is the iteration count that makes this script take a long time to complete. It uses this to get several rounds of performance data from the processes the health service spawns. This is then averaged. One way of reducing runtime is to set a lower number for ProcessIterationCount. Another is to set the original script timeout value back to 300 sec, instead of the 120 I have set. 
    • If you have the time can you try to run this version of the script on one of the servers that are timing out? I have changed some more code logic to hopefully optimize better the filtering of what processes it should get the performance counters from. 
      There are still many places where sleep is used, so it is impossible to get it to run faster than the combined values of these sleep commands.