Applications Systems

Windows Services Monitor polled via WinRM shows as Unknown in SAM

The Windows Services component status appears as Unknown in SAM, with no additional error messages displayed in the Web Console.

First published date

7/29/2025 1:00 PM

Last published date

7/29/2025 4:43 PM

Overview

Traditionally, the Windows Services component is polled using WMI queries. However, with the introduction of WinRM-based polling, new query errors may occur, causing the component to show as Unknown.

Product section

Server Application Monitor

Cause

The polling query is still using a WMI query to select the Win32_Service class on the target machine running PowerShell. This can cause failures when WinRM is used or when performance counters on the target machine are corrupted.

Sample Query:

Get-WmiObject -Class Win32_Service

Querying WMI class 'Win32_Service' with 'select Name,Caption,State,ProcessId from Win32_Service where Name = 'DNS' OR Caption = 'DNS''

Resolution

Rebuild the corrupted performance counters on the monitored machine by running the following commands from an Administrative Command Prompt. Press ENTER after each command. 

-- Scripts are not supported under any SolarWinds support program or service.
-- Scripts are provided AS IS without warranty of any kind. SolarWinds further
-- disclaims all warranties including, without limitation, any implied warranties
-- of merchantability or of fitness for a particular purpose. The risk arising
-- out of the use or performance of the scripts and documentation stays with you.
-- In no event shall SolarWinds or anyone else involved in the creation,
-- production, or delivery of the scripts be liable for any damages whatsoever
-- (including, without limitation, damages for loss of business profits, business
-- interruption, loss of business information, or other pecuniary loss) arising
-- out of the use of or inability to use the scripts or documentation.

cd c:\windows\system32
lodctr /R

cd c:\windows\sysWOW64
lodctr /R

WINMGMT.EXE /RESYNCPERF
After running these commands, restart the following services:
  • Performance Logs and Alerts service
  • Windows Management Instrumentation (WMI) service
This process rebuilds the performance counters and resolves issues related to WMI provider load failures.

 

For additional information, see Invalid Query error within component monitor in SAM.

If the issue persists after rebuilding performance counters, consider verifying WMI connectivity and WinRM configuration on the target machine.