Skip to main content

Windows (WMI)

Windows (WMI)

Plugin: wmi.plugin Module: windows

Maintained by Netdata

Overview​

Monitor Windows hosts remotely over WMI without installing anything on them: CPU, memory, processes, RDP sessions, network, disks, SMB, time sync and ping.

A Netdata Agent on another machine reads each host's built-in Windows Management Instrumentation (WMI) data. Use it where the Netdata Agent cannot be installed on the Windows hosts themselves. For each host you get:

  • CPU utilization by mode (user, privileged, interrupts and DPCs), in total and per logical processor;
  • physical and available memory, commit charge, paging activity, page faults, kernel memory pools, the system cache and page lists, the usage of each paging file, and the free and standby memory of each NUMA node;
  • the number of processes and threads, context switches, processor queue length and uptime;
  • active and inactive Remote Desktop (Terminal Services) sessions;
  • how far the host's clock is ahead of or behind the poller's;
  • how the Windows Time service keeps the host's clock synchronized: its offset from the host's time source, the round trip of its latest NTP request and the number of time sources that answer it;
  • traffic, packets, errors, drops, speed and output queue length per network interface, and the total traffic of the host;
  • TCP and UDP packets per IP version, TCP connections, connection opens, failures and resets, TCP retransmissions, and UDP errors;
  • available and used space per fixed drive;
  • bandwidth, operations, latency, utilization and queue per physical disk, and the total disk I/O of the host;
  • the SMB file server's traffic, sessions, logons, open files, logon and access errors and resource shortages, and the open files, requests, connections and traffic of each share;
  • round-trip time and packet loss of ICMP ping from the poller;
  • a node of its own in Netdata, named after the Windows computer name and labeled with its Windows version, hardware and default network address;
  • host status: when the poller can no longer collect from the host, its node turns Stale and an alert on the poller notifies you.

The charts use the same contexts as the Netdata Agent running on Windows, so the dashboard and the stock Windows alerts treat these hosts like Windows hosts that run the Agent. The ping charts use the contexts of Netdata's Ping collector, so its stock ping alerts apply too. TCP connections, connection opens, failures and resets, retransmissions, UDP errors and the Windows Time service's offset from the time source, which the Netdata Agent on Windows does not chart, use the contexts of the Netdata Agent on Linux; the Linux TCP and UDP alerts do not apply to them. The clock offset from the poller, the NTP round trip and time sources, and the SMB server's server-wide counters, which no other collector charts this way, have contexts of their own.

wmi.plugin runs on a Netdata Agent, the poller. Every update_every seconds (30 by default) it connects to each configured Windows host, runs one read-only WQL query in the root\cimv2 namespace per enabled metric group (four for the memory group, six for the network group, two for the system, disk and SMB groups, and one more when a physical disk appears, until it has read the disk's model), and disconnects. Every five minutes the same connection also reads the host's system information for its node labels. The plugin only reads: it changes nothing on the host and opens no shell.

While the queries run, the plugin also pings the host: it sends three ICMP echo requests, 100 ms apart, and charts the replies.

For the clock offset, the plugin compares the time the host reports in the System query with the poller's clock at the middle of that query. The result is accurate to half the query's duration, usually a few tens of milliseconds; a collection whose System query takes longer than one second charts no offset.

A collection that fails publishes nothing for the host. When no collection has succeeded for 3 × update_every + timeout seconds (105 by default, about three missed collections), the Agent marks the host's node Stale, as it does for a child Agent that stops streaming. The Agent checks for stale nodes at that same interval, so marking can take up to about twice as long. The next successful collection makes the node live again. On the poller, the wmi_host_last_collected_secs alert (wmi.plugin.conf) counts the seconds since each job's last successful collection, turns critical after two to three missed collections (more when collections themselves are slow), and notifies the sysadmin role. It starts evaluating after the job's second successful collection. Its value is on the job's Data Collection Duration chart of the poller, so the alert table below, which covers the host's own charts, does not list it.

It authenticates as the configured Windows account with NTLMv2 and uses one of two transports:

TransportPorts on the Windows hostProtection
DCOM (default)TCP 135 (RPC endpoint mapper) and the dynamic RPC port of the WMI serviceNTLMv2 with RPC packet privacy (encrypted)
WinRMTCP 5986 (HTTPS listener)TLS; the poller verifies the listener certificate

These are the WMI classes it reads, for audit and access reviews:

DataWMI classes
CPUWin32_PerfRawData_Counters_ProcessorInformation
MemoryWin32_OperatingSystem, Win32_PerfRawData_PerfOS_Memory, Win32_PerfRawData_PerfOS_PagingFile, Win32_PerfRawData_PerfOS_NUMANodeMemory
SystemWin32_PerfRawData_PerfOS_System, Win32_PerfRawData_LocalSessionManager_TerminalServices
NetworkWin32_PerfRawData_Tcpip_NetworkInterface, Win32_PerfRawData_Tcpip_NetworkAdapter, Win32_PerfRawData_Tcpip_TCPv4, Win32_PerfRawData_Tcpip_TCPv6, Win32_PerfRawData_Tcpip_UDPv4, Win32_PerfRawData_Tcpip_UDPv6
DiskWin32_LogicalDisk, Win32_PerfRawData_PerfDisk_PhysicalDisk, Win32_DiskDrive
SMBWin32_PerfRawData_PerfNet_Server, Win32_PerfRawData_Counters_SMBServerShares
Time synchronizationWin32_PerfRawData_MicrosoftWindowsW32TimePerf_WindowsTimeService
Node labelsWin32_OperatingSystem, Win32_ComputerSystem, Win32_Processor, Win32_PhysicalMemory, Win32_LogicalDiskToPartition, Win32_IP4RouteTable, Win32_NetworkAdapter, Win32_NetworkAdapterConfiguration

This collector is only supported on the following platforms:

  • Linux
  • Windows

This collector supports collecting metrics from multiple instances of this integration.

The Windows account needs remote read access to WMI on each monitored host. Members of the host's local Administrators group have it. For a dedicated non-administrator account, grant:

PermissionNeeded when
Enable Account and Remote Enable on the root\cimv2 WMI namespaceAlways
Membership in the local Distributed COM Users grouptransport: dcom
Membership in the local Remote Management Users grouptransport: winrm
Membership in the local Performance Monitor Users groupAlways

The plugin only reads: do not grant Execute Methods, write or full-control permissions. See Securing a remote WMI connection.

On a Linux poller, wmi.plugin needs the CAP_NET_RAW capability to send ICMP echo requests. The installer grants it that capability and no other privilege.

Default Behavior​

Auto-Detection​

The plugin does not discover Windows hosts. The stock configuration has no jobs, so it contacts no host until you add one.

Limits​

  • Authentication is NTLMv2 only. Hosts or domains that block NTLM and accept only Kerberos cannot be monitored.
  • Every collection logs in again. With a wrong or expired password, each collection adds one failed logon (and each autodetection_retry attempt while the job is starting), which can lock the account under an account lockout policy.
  • A WinRM listener with CbtHardeningLevel set to Strict rejects the plugin, because it sends no TLS channel binding token.
  • Rates, such as traffic, packets and errors, appear from the second collection after a job starts, because a rate needs two readings.
  • When a host restarts, counters that Windows keeps in 32 bits, such as context switches, start again from zero. If such a counter was close to its 32-bit maximum before the restart, the Agent reads the drop as a counter wrap and its chart shows one spike.
  • Disk space covers fixed drives that have a drive letter. Volumes mounted only into a folder, removable drives and network drives are not charted.
  • Every share of the host gets seven charts, as on the Netdata Agent running on Windows, including the hidden administrative shares that every Windows host has (C$ and one for each other drive, ADMIN$, IPC$). A file server with 200 shares gets 1,400 share charts; switch off collectors.smb for a host whose SMB charts you do not need.
  • Some stock packet alerts expect the one-second collection of the Netdata Agent running on Windows. At the default update_every of 30, 10s_received_packets_storm cannot reach its thresholds; net_interface_inbound_packets and net_interface_outbound_packets add up per-second rates, so they show the packets divided by update_every; and the drop-ratio alerts evaluate only interfaces that average more than about 500 received or 50 sent packets per second, and report 0 below that.
  • Every job pings its host; ping cannot be switched off. A host that does not answer ICMP echo requests, for example because Windows Firewall blocks them, shows 100% packet loss in every collection and raises the ping_host_reachable alert.
  • Ping charts update only in collections whose WMI queries succeed. A host that is down leaves a gap in the ping charts instead of 100% packet loss, so the ping alerts do not report it; its node turns Stale and the wmi_host_last_collected_secs alert reports it instead.
  • A host that cannot be reached when its job starts gets no node and no host status alert until the job collects from it, twice for the alert. Set autodetection_retry so the job keeps trying.
  • Stopping or removing a job leaves its charts on the generated node, which then turns Stale. A job restarted after an edit does not remove the charts it no longer sends, such as those of a metric group you switched off: they stay on the node without new data.
  • With update_every shorter than timeout, one unusually slow collection can raise wmi_host_last_collected_secs for a moment. Keep update_every at least as long as timeout, as the defaults (30 and 15 seconds) are.
  • After five failed collections in a row, the plugin waits longer between attempts, up to 10 minutes more than update_every. A host that comes back after a long outage can take that long to turn live again.
  • system_reboot_detection sees a reboot only when a collection succeeds within the host's first 10 minutes of uptime. After a long outage, the longer wait between attempts can miss that window; the wmi_host_last_collected_secs alert reports the outage instead.
  • A collection must finish within timeout (15 seconds by default); a collection that does not is discarded and leaves a gap in every chart of the host.
  • The clock offset is measured against the poller's clock, so it includes the poller's own error with the opposite sign: a poller whose clock is 2 seconds behind shows every host 2 seconds ahead. Keep the poller's clock synchronized. When every host of one poller shows a similar offset, check the poller's clock first.
  • Time synchronization needs Windows Server 2016 or later, which added the Windows Time service's counters. On an older host its query fails in every collection and the job logs a warning once a minute; switch off collectors.time for that host. The charts show the Windows Time service's own synchronization, not that of another NTP client installed on the host.

Performance Impact​

The poller's own cost is small: a few short-lived connections per job per collection.

On each Windows host, every collection costs up to eighteen WMI queries, one more while it reads the model of a physical disk that appeared, run by the WMI provider host process (WmiPrvSE.exe), and three ICMP echo requests. DCOM opens two authenticated TCP connections per collection (the RPC endpoint mapper and the WMI service); WinRM opens one authenticated HTTPS connection. Every five minutes the node labels add up to eight small queries. To reduce the load, raise update_every or switch off the metric groups you do not need under collectors.

Setup​

Prerequisites​

Build the plugin from source​

Netdata packages do not include this experimental plugin yet. On the poller, build and install Netdata from source with the plugin enabled:

./netdata-installer.sh --enable-plugin-wmi

CMake builds use -DENABLE_PLUGIN_WMI=ON. Check that wmi.plugin is in the Netdata plugins directory, usually /usr/libexec/netdata/plugins.d/.

The installer also gives wmi.plugin the CAP_NET_RAW capability, which ping needs. When the setcap tool is missing, or the installer runs inside a container, it does not, and prints a warning; the plugin then collects without ping charts until you grant the capability (see the ICMP ping disabled error under Troubleshooting).

Allow the poller through the Windows firewall​

On each Windows host, allow inbound connections from the poller for the transport you use. In PowerShell as Administrator, replace 192.0.2.10 with the poller's address.

For DCOM, enable the built-in WMI rules and limit them to the poller:

Enable-NetFirewallRule -DisplayGroup "Windows Management Instrumentation (WMI)"
Set-NetFirewallRule -DisplayGroup "Windows Management Instrumentation (WMI)" -RemoteAddress 192.0.2.10

For WinRM, allow the HTTPS listener port:

New-NetFirewallRule -DisplayName "WinRM HTTPS from Netdata" -Direction Inbound -Protocol TCP -LocalPort 5986 -RemoteAddress 192.0.2.10 -Action Allow

For the ping charts, allow ICMP echo requests from the poller:

New-NetFirewallRule -DisplayName "ICMP echo from Netdata" -Direction Inbound -Protocol ICMPv4 -IcmpType 8 -RemoteAddress 192.0.2.10 -Action Allow

For a host monitored over IPv6, use -Protocol ICMPv6 -IcmpType 128.

Network firewalls between the poller and the host need the same ports and ICMP echo. DCOM's WMI port is dynamic, by default in the TCP range 49152-65535.

Create a WinRM HTTPS listener​

WinRM only. The host needs a server authentication certificate whose subject or subject alternative name matches the host you configure, in the computer's Personal certificate store. Then create the listener in PowerShell as Administrator:

winrm quickconfig -transport:https

If a private CA issued the certificate, copy the CA certificate in PEM format to the poller and set tls_ca to its path. See Configure WinRM for HTTPS.

Grant the monitoring account access to WMI​

Skip this step for an account in the host's local Administrators group. Otherwise, grant the permissions listed under Overview:

  1. Add the account to the local groups, for example for DCOM:

    Add-LocalGroupMember -Group "Distributed COM Users" -Member 'EXAMPLE\monitor'
    Add-LocalGroupMember -Group "Performance Monitor Users" -Member 'EXAMPLE\monitor'

    For WinRM, use the group Remote Management Users instead of Distributed COM Users.

  2. Run wmimgmt.msc, open the properties of WMI Control, and on the Security tab select Root\CIMV2. Click Security, add the account, and allow Enable Account and Remote Enable.

A local account other than the built-in Administrator gets a filtered token for remote connections even when it is an administrator (remote UAC), so treat it as a non-administrator account and grant the permissions above.

Configuration​

Options​

Each job monitors one Windows host. Set update_every or autodetection_retry at the top of the file to apply them to every job.

GroupOptionDescriptionDefaultRequired
ConnectionhostHostname or IP address of the Windows host.yes
transportProtocol that carries the WMI queries. DCOM uses TCP 135 and a dynamic RPC port; WinRM uses HTTPS on TCP 5986.dcomno
tls_caPath on the poller to the PEM file of the CA that issued the WinRM listener certificate. Leave empty to use the system trust store.no
authAuthentication protocol for the Windows account. NTLMv2 is the only supported protocol.yes
usernameWindows account that reads WMI on the host, as DOMAIN\user, user@domain or a local account name.yes
passwordPassword of the Windows account.yes
Collectionupdate_everyData collection interval, in seconds.30no
autodetection_retryHow often to retry the initial connection when the job fails to start, in seconds. Zero disables retries.0no
timeoutTime limit for one collection, including the connection and every enabled query, in seconds.15no
collectorsMetric groups to collect. Each enabled group runs one WMI query per collection, the memory group four, the network group six, and the system, disk and SMB groups two. Keep at least one group enabled.no
collectors.cpuCollect processor utilization by mode, in total and per logical processor.yesno
collectors.memoryCollect physical and available memory, commit charge, paging activity, page faults, kernel memory pools, the system cache and page lists, the usage of each paging file, and the free and standby memory of each NUMA node.yesno
collectors.systemCollect the number of processes and threads, context switches, processor queue length, uptime, the host's clock offset and its Remote Desktop sessions.yesno
collectors.networkCollect traffic, packets, errors, drops, speed and output queue length per network interface, the host's total traffic, and TCP and UDP packets, connections and errors.yesno
collectors.diskCollect available and used space per fixed drive, and bandwidth, operations, latency, utilization and queue per physical disk.yesno
collectors.smbCollect the SMB file server's traffic, sessions, logons, open files, logon and access errors and resource shortages, and the open files, requests, connections and traffic of each share.yesno
collectors.timeCollect the Windows Time service's offset from its time source, NTP round-trip delay and number of answering time sources. Needs Windows Server 2016 or later.yesno
Virtual NodevnodeAssociates this job with a Virtual Node.no
password​

Keep the password out of the configuration file with a secret reference, for example ${env:WMI_PASSWORD} with the variable set in the Netdata service environment. See secrets management.

collectors.cpu​

As on the Netdata Agent running on Windows, each mode is its share of the time all modes accumulated in the interval. The privileged time Windows reports (system) already includes the interrupt (irq) and DPC (dpc) time, so those two also count within system.

vnode​

Leave vnode empty and the job creates a node for the Windows host. Its identity comes from host: renaming the Windows computer keeps the node and its history, while changing host creates a new node. The node is named after the Windows computer name, carries host in the address label, and gets these labels from WMI, refreshed every five minutes. A label is left out when Windows does not report its value unambiguously.

LabelsMeaning
_os_name, _os_version, _os_marketing_version, _os_edition, _kernel_versionWindows product, edition, version and build
_hw_sys_vendor, _hw_product_name, _virtualization, _virt_detection, _hw_product_typeManufacturer, model, and the platform of a recognized virtual machine
_system_cores, _architecture, _system_cpu_model, _system_cpu_freqLogical processors, architecture, processor model and clock in Hz
_system_ram_totalSum of the installed memory modules, in bytes
_system_disk_spaceTotal partition size of the fixed drives, in bytes; requires the disk group
_net_default_iface, _net_default_iface_ip, _net_default_iface_detectionInterface and IPv4 address of the default route

The generated node turns Stale after about three missed collections, as the Overview describes.

Set vnode to the name of a virtual node defined in vnodes.conf to use its name and labels instead; the job then reads no system information. Give that node the label _os: windows, which the generated node has, so the stock Windows alerts apply to it. Such a node turns Stale only after its own stale_after time (or _node_stale_after_seconds label); without one it stays live, with gaps in its charts, while the host is down.

via File​

The configuration file name for this integration is wmi/windows.conf.

You can edit the configuration file using the edit-config script from the Netdata config directory.

cd /etc/netdata 2>/dev/null || cd /opt/netdata/etc/netdata
sudo ./edit-config wmi/windows.conf
Examples​
Basic​

Monitor one Windows host over DCOM. The password comes from the WMI_PASSWORD environment variable of the Netdata service.

jobs:
- name: fileserver
host: fileserver.example.com
auth: ntlm
username: 'EXAMPLE\monitor'
password: '${env:WMI_PASSWORD}'

WinRM over HTTPS with a private CA​

Use the host's WinRM HTTPS listener instead of DCOM, trusting the CA that issued its certificate.

jobs:
- name: fileserver
host: fileserver.example.com
transport: winrm
tls_ca: /etc/netdata/ssl/windows-ca.pem
auth: ntlm
username: 'EXAMPLE\monitor'
password: '${env:WMI_PASSWORD}'

CPU and memory only​

Skip the system, network, disk, SMB and time synchronization queries.

jobs:
- name: fileserver
host: fileserver.example.com
auth: ntlm
username: 'EXAMPLE\monitor'
password: '${env:WMI_PASSWORD}'
collectors:
system: false
network: false
disk: false
smb: false
time: false

Multi-instance​

Monitor several Windows hosts with one account. Each job creates its own node.

jobs:
- name: fileserver
host: fileserver.example.com
auth: ntlm
username: 'EXAMPLE\monitor'
password: '${env:WMI_PASSWORD}'

- name: sqlserver
host: sql01.example.com
auth: ntlm
username: 'EXAMPLE\monitor'
password: '${env:WMI_PASSWORD}'

Alerts​

The following alerts are available:

Alert nameOn metricDescription
10min_cpu_usage system.cpuAverage CPU utilization over the last 10 minutes
disk_space_usage disk.spaceTotal space utilization of disk ${label:mount_point}
disk_fill_rate disk.spaceaverage rate the disk fills up (positive), or frees up (negative) space, for the last hour
out_of_disk_space_time disk.spaceEstimated time the disk ${label:mount_point} will run out of space, if the system continues to add data with the rate of the last hour
10min_disk_utilization disk.utilAverage percentage of time ${label:device} disk was busy over the last 10 minutes
interface_speed net.netNetwork interface ${label:device} current speed
1m_received_traffic_overflow net.netAverage inbound utilization for the network interface ${label:device} over the last minute
1m_sent_traffic_overflow net.netAverage outbound utilization for the network interface ${label:device} over the last minute
net_interface_inbound_packets net.packetsReceived packets for the network interface ${label:device} in the last 10 minutes
net_interface_outbound_packets net.packetsSent packets for the network interface ${label:device} in the last 10 minutes
inbound_packets_dropped_ratio net.dropsRatio of inbound dropped packets for the network interface ${label:device} over the last 10 minutes
outbound_packets_dropped_ratio net.dropsRatio of outbound dropped packets for the network interface ${label:device} over the last 10 minutes
1m_received_packets_rate net.packetsAverage number of packets received by the network interface ${label:device} over the last minute
10s_received_packets_storm net.packetsRatio of average number of received packets for the network interface ${label:device} over the last 10 seconds, compared to the rate over the last minute
network_interface_output_queue_length net.queue_lengthThe Output Queue Length on interface ${label:device} should be zero, otherwise there are delays and bottlenecks.
ping_host_reachable ping.host_packet_lossNetwork host ${label:host} reachability status
ping_packet_loss ping.host_packet_lossPacket loss percentage to the network host ${label:host} over the last 10 minutes
ping_host_latency ping.host_rttAverage latency to the network host ${label:host} over the last 10 seconds
ram_in_use system.ramPhysical memory in use, as a percentage of total RAM. The standby cache counts as available, not in use
system_reboot_detection system.uptimeSystem has rebooted within the last 10 minutes
committed_memory_utilization mem.committedCommit charge as a percentage of the commit limit (RAM plus paging files). Allocations fail when it reaches the limit and the paging files cannot grow
wmi_host_clock_offset wmi.clock_offsetAverage difference over the last 5 minutes between the Windows host's clock and the clock of the Netdata Agent that collects it over WMI. When every host of one Agent shows it, check that Agent's clock first.
wmi_host_time_sources wmi.clock_sync_sourcesMost NTP time sources that answered the Windows host's time service in any collection of the last hour. Zero means the host keeps time on its own clock, which drifts, unless something other than NTP synchronizes it.

Metrics​

Metrics grouped by scope.

The scope defines the instance that the metric belongs to. An instance is uniquely identified by a set of labels.

  • Charts belong to the Windows host's node, not to the poller.
  • CPU utilization and the per-second rates, such as traffic, packets, errors, paging and page faults, are averages over each collection interval, computed from Windows' raw performance counters, so a short spike counts toward the interval it happens in.
  • Memory sizes, processes, threads, TCP connections (ip.tcpsock), the processor queue length and the disk queue (disk.qops) are the values at the moment of the collection. As on the Netdata Agent running on Windows, system.processes counts every process on the host as running.
  • As on the Netdata Agent running on Windows, mem.swap and mem.committed show the commit charge against the commit limit, which counts physical memory and all paging files; mem.pagefile_usage shows how full each paging file is.
  • As on the Netdata Agent running on Windows, mem.system_pool_allocs shows how fast the number of outstanding pool allocations grows, and 0 while it shrinks.
  • As on the Netdata Agent running on Windows, disk utilization, operation times (disk.await, disk.svctm) and sizes (disk.avgsz) are averages over each collection interval, and an interval in which no operation completed shows a time and size of 0. disk.busy shows Windows' % Disk Time, which adds up the time of concurrent operations, so it can exceed 1000 ms per second.
  • The ip.* TCP charts add up IPv4 and IPv6, as the Netdata Agent on Linux counts TCP and as the Netdata Agent on Windows charts ip.tcppackets; ipv4.* and ipv6.* charts show one version. The charts that use Linux contexts have only the dimensions Windows counts: ip.tcphandshake has no OutRsts or SynRetrans, ip.tcperrors only RetransSegs, and the udperrors charts only InErrors and NoPorts.
  • A metric group whose query fails leaves a gap in its charts for that collection, while the other groups continue; the ip.* TCP charts need both the IPv4 and the IPv6 query. A zero is always a reported value.
  • Ping packet loss is the share of the three echo requests of a collection that got no reply. Round-trip times come from the replies, so a collection without any reply has packet loss but no round-trip time.
  • terminal_services.sessions counts the host's Remote Desktop sessions at the moment of the collection, as Windows does: active sessions have a connected user, inactive ones do not, such as disconnected sessions, the services session and the console's logon screen. Even a host nobody is logged on to has inactive sessions.
  • wmi.clock_offset is the host's clock minus the poller's: a positive value means the host's clock is ahead.
  • system.clock_sync_offset is how far the host's clock is from its own time source, as the Windows Time service computes it from each NTP answer; it falls while the service corrects the clock. Windows reports only its size, so unlike on the Netdata Agent on Linux it is never negative. Between answers it only falls, so it does not show the drift of a host whose time source stopped answering; wmi.clock_offset does.
  • wmi.clock_sync_roundtrip_delay is the round trip of the Windows Time service's latest NTP request and changes only with its next request. wmi.clock_sync_sources counts the time servers that answer the host's NTP client; it is 0 on a host that keeps time without NTP.
  • The wmi.smb_server_* charts cover the host's whole SMB file service, as Windows' Server counters count it; the smb.server_shares_* charts show it per share, as on the Netdata Agent running on Windows. wmi.smb_server_logons counts every logon attempt, failed ones included. In wmi.smb_server_access_errors, logon counts failed logons, access_permissions file opens refused with access denied, and granted_access denied accesses to files already open. In wmi.smb_server_resource_errors, system counts internal server errors, work_item_shortages and blocking_requests_rejected requests the server had no free work item for, and the pool failures failed kernel memory allocations.

Per Windows (WMI) instance​

The monitored Windows host.

This scope has no labels.

Metrics:

MetricDescriptionDimensionsUnit
system.cpuTotal CPU Utilizationirq, user, system, dpc, idlepercentage
system.ramSystem RAMfree, usedMiB
mem.availableAvailable RAM for applicationsavailMiB
mem.swapSystem Swapfree, usedMiB
mem.swap_iopsSwap Operationsread, writeoperations/s
mem.swapioSwap I/Oin, outKiB/s
mem.committedCommitted Memorycommitted, limitbytes
mem.system_cacheSystem Cache Memorycache, peak, residentbytes
mem.page_listsMemory Page Listsfree, modified, standby_core, standby_normal, standby_reservebytes
mem.system_pool_sizeSystem Memory Poolpaged, non-pagedbytes
mem.system_pool_pagedPaged System Memory Poolresidentbytes
mem.system_pool_allocsSystem Pool Allocationspaged, non-pagedallocations/s
mem.system_page_table_entriesUnused page table entries.freepages
mem.system_codeSystem Code Memoryresident, totalbytes
mem.system_driversSystem Driver Memoryresident, totalbytes
mem.pgfaultsMemory Page Faultsminor, majorfaults/s
mem.page_faults_breakdownMemory Page Fault Breakdowncache, demand_zero, transition, write_copiesfaults/s
mem.transition_repurposedTransition Pages Repurposedrepurposedpages/s
system.processesSystem Processesrunningprocesses
system.threadsThreadsthreadsthreads
system.ctxtCPU Context Switchesswitchescontext switches/s
system.processor_queue_lengthThe number of threads in the processor queue.threadsthreads
system.uptimeSystem Uptimeuptimeseconds
terminal_services.sessionsTerminal Services sessionsactive, inactivesessions
wmi.clock_offsetClock Offset From the Collecting Agentoffsetmilliseconds
wmi.clock_sync_roundtrip_delayNTP Round-Trip Delaydelaymilliseconds
wmi.clock_sync_sourcesActive NTP Time Sourcesactivesources
system.clock_sync_offsetComputed Time Offset Between Local System and Reference Clockoffsetmilliseconds
system.ioDisk I/Oreads, writesKiB/s
system.netPhysical Network Interfaces Aggregated Bandwidthreceived, sentkilobits/s
ip.tcppacketsTCP Packetsreceived, sentpackets/s
ip.tcpsockTCP Connectionsconnectionsactive connections
ip.tcpopensTCP Opensactive, passiveconnections/s
ip.tcphandshakeTCP Handshake IssuesEstabResets, AttemptFailsevents/s
ip.tcperrorsTCP ErrorsRetransSegspackets/s
ipv4.tcppacketsIPv4 TCP Packetsreceived, sentpackets/s
ipv6.tcppacketsIPv6 TCP Packetsreceived, sentpackets/s
ipv4.udppacketsIPv4 UDP Packetsreceived, sentpackets/s
ipv4.udperrorsIPv4 UDP ErrorsInErrors, NoPortsevents/s
ipv6.udppacketsIPv6 UDP Packetsreceived, sentpackets/s
ipv6.udperrorsIPv6 UDP ErrorsInErrors, NoPortsevents/s
wmi.smb_server_trafficSMB Server Trafficreceived, sentbytes/s
wmi.smb_server_sessionsSMB Server Sessionsactivesessions
wmi.smb_server_sessions_endedSMB Server Sessions Endedlogged_off, timed_out, errored_out, forced_offsessions/s
wmi.smb_server_logonsSMB Server Logonslogonslogons/s
wmi.smb_server_access_errorsSMB Server Logon and Access Errorslogon, access_permissions, granted_accesserrors/s
wmi.smb_server_open_filesSMB Server Open Filesopenfiles
wmi.smb_server_files_openedSMB Server Files Openedopenedfiles/s
wmi.smb_server_resource_errorsSMB Server Internal Errors and Resource Shortagessystem, work_item_shortages, blocking_requests_rejected, paged_pool_failures, nonpaged_pool_failuresevents/s

Per paging file​

A paging file of the host. Windows creates one, C:\pagefile.sys, by default.

Labels:

LabelDescription
pagefilePath of the paging file, for example C:/pagefile.sys. Backslashes are shown as forward slashes.

Metrics:

MetricDescriptionDimensionsUnit
mem.pagefile_usagePaging file usagefree, usedbytes

Per NUMA node​

A NUMA node of the host, a group of processors and the memory attached to them. Most virtual machines and single-socket servers have one.

Labels:

LabelDescription
nodeNumber of the NUMA node, for example 0.

Metrics:

MetricDescriptionDimensionsUnit
mem.numa_node_mem_usageNUMA Node Memory Usagefree, standbybytes

Per logical processor​

A logical processor of the host.

Labels:

LabelDescription
cpuLogical processor as cpuN, numbered through the host's NUMA nodes in order, for example cpu0.

Metrics:

MetricDescriptionDimensionsUnit
cpu.cpuCore Utilizationirq, user, system, dpc, idlepercentage

Per network interface​

A network interface or adapter as Windows performance counters list it, including virtual and tunnel adapters, that has sent or received traffic since its counters started.

Labels:

LabelDescription
devicePerformance counter name of the interface, for example Intel[R] PRO_1000 MT Network Connection. Windows writes parentheses as square brackets and # or / as underscores.
interface_typereal for an interface of the Network Interface counters, virtual for an adapter that only the Network Adapter counters list, as the Netdata Agent on Windows labels them.

Metrics:

MetricDescriptionDimensionsUnit
net.netBandwidthreceived, sentkilobits/s
net.packetsPacketsreceived, sentpackets/s
net.speedInterface Speedspeedkilobits/s
net.errorsInterface Errorsinbound, outbounderrors/s
net.dropsInterface Dropsinbound, outbounddrops/s
net.queue_lengthInterface Output Queue Lengthlengthpackets
net.rsc_connectionsActive TCP Connections Offloaded by RSCconnectionsconnections
net.rsc_packetsTCP RSC Coalesced Packetspacketspackets/s
net.rsc_exceptionsTCP RSC Exceptionsexceptionsexceptions/s
net.rsc_average_packet_sizeTCP RSC Average Packet Sizeaveragebytes
net.chimney_connectionsActive TCP Connections Offloaded with Chimneyconnectionsconnections
net.unknown_protocol_packetsPackets Received with Unknown Protocolinboundpackets/s

Per drive​

A fixed drive with a drive letter that Windows does not report as read-only.

Labels:

LabelDescription
mount_pointDrive letter, for example C:.
drive_typeAlways fixed, the only drive type the plugin reads.
filesystemFile system of the drive, for example NTFS, or unknown when Windows reports none.
rw_modeAlways rw, because read-only drives are not charted.
serial_numberVolume serial number in hexadecimal, for example 0x1A2B3C4D, or 0x0 when Windows reports none.

Metrics:

MetricDescriptionDimensionsUnit
disk.spaceDisk Space Usageavail, usedGiB

Per physical disk​

A physical disk as Windows performance counters list it, including a virtual machine's virtual disks and the volumes a storage array presents as disks.

Labels:

LabelDescription
deviceDisk number, for example Disk 0.
mount_pointDrive letters of the disk's volumes, for example C: or C: D:. Left out for a disk without a volume that has a drive letter.
modelModel of the disk, for example QEMU HARDDISK. Left out when Windows does not list the disk among its disk drives.
device_idDevice path of the disk, for example //./PHYSICALDRIVE0. Backslashes are shown as forward slashes. Left out when Windows does not list the disk among its disk drives.

Metrics:

MetricDescriptionDimensionsUnit
disk.ioDisk I/O Bandwidthreads, writesKiB/s
disk.avgszAverage Completed I/O Operation Bandwidthreads, writesKiB/operation
disk.opsDisk Completed I/O Operationsreads, writesoperations/s
disk.qopsDisk Current I/O Operationsoperationsoperations
disk.utilDisk Utilization Timeutilization% of time working
disk.busyDisk Busy Timebusymilliseconds
disk.iotimeDisk Total I/O Timereads, writesmilliseconds/s
disk.awaitAverage Completed I/O Operation Timereads, writesmilliseconds/operation
disk.svctmAverage Service Timesvctmmilliseconds/operation
disk.splitSplit I/O Operationsdiscardsoperations/s

Per SMB share​

A share the host's SMB server serves, including the hidden administrative shares such as C$, ADMIN$ and IPC$.

Labels:

LabelDescription
shareShare as the Windows performance counters name it, with backslashes shown as forward slashes and * and $ as underscores, for example //_/C_ for the counter set's \\*\C$.

Metrics:

MetricDescriptionDimensionsUnit
smb.server_shares_current_open_file_countCurrent open file count on the SMB shareopenfiles
smb.server_shares_write_requestsWrite requests on the SMB sharewritesrequests/s
smb.server_shares_read_requestsRead requests on the SMB sharereadsrequests/s
smb.server_shares_metadata_requestsMetadata requests on the SMB sharemetadatarequests/s
smb.server_shares_files_openedFiles opened on the SMB shareopenedfiles/s
smb.server_shares_tree_connectsTree connects on the SMB shareconnectsconnections
smb.server_shares_trafficTraffic on the SMB sharereceived, sentbytes/s

Per ping target​

The Windows host as the poller pings it.

Labels:

LabelDescription
hostThe job's host option, the name or address the poller pings.

Metrics:

MetricDescriptionDimensionsUnit
ping.host_rttPing round-trip timemin, max, avgmilliseconds
ping.host_std_dev_rttPing round-trip time standard deviationstd_devmilliseconds
ping.host_packet_lossPing packet losslosspercentage

Troubleshooting​

Known Errors​

secret resolver: provider failure: job output: collector lifecycle failed; resolved configuration details redacted​

When

The job's password, or another option, is a secret reference such as ${env:WMI_PASSWORD}.

Cause

The Agent could not resolve the reference, for example because the variable is not set in the Netdata service environment. The Agent hides the details because they can contain resolved values. The plugin's own messages, listed below, still appear for jobs that use secret references.

Fix

Set the variable in the environment of the Netdata service, or correct the reference, as described in secrets management.

auth must be ntlm​

Cause

The job omits auth or sets another value. The option has no default.

Fix

Add auth: ntlm to the job.

transport must be dcom or winrm​

Cause

transport has a value other than dcom or winrm.

Fix

Set transport: winrm for the WinRM HTTPS listener, or remove transport to use DCOM.

tls_ca requires the winrm transport​

Cause

The job sets tls_ca without transport: winrm. DCOM does not use TLS.

Fix

Add transport: winrm, or remove tls_ca to keep DCOM.

could not load tls_ca: could not read certificate "/etc/netdata/ssl/windows-ca.pem": open "/etc/netdata/ssl/windows-ca.pem": no such file or directory​

When

tls_ca is set. Jobs that use secret references show only could not load tls_ca.

Cause

The file does not exist, or the netdata user cannot read it. The plugin reads it without its elevated privileges.

Fix

Set tls_ca to the absolute path of the CA certificate on the poller, and make the file readable by the netdata user.

could not load tls_ca: could not parse any PEM certificates "/etc/netdata/ssl/windows-ca.pem"​

When

tls_ca is set. Jobs that use secret references show only could not load tls_ca.

Cause

The file holds no certificate in PEM format, for example a certificate exported in DER format.

Fix

Convert the certificate to PEM, for example with openssl x509 -inform der -in ca.cer -out ca.pem, and point tls_ca at the result.

host must be a Windows hostname or IP address without a URL or port​

Cause

host is empty or contains a scheme, path, port or other characters that are not part of a hostname.

Fix

Set host to the bare name or address, for example fileserver.example.com instead of https://fileserver.example.com:5986.

username is required​

Cause

username is empty, or names a domain with nothing after the backslash.

Fix

Set the full account name, such as EXAMPLE\monitor or [email protected].

password is required​

Cause

password is empty, or its secret reference resolved to an empty value.

Fix

Set the password, or give the referenced variable a value in the Netdata service environment.

timeout must be positive​

Cause

timeout is zero or negative.

Fix

Remove timeout to use the default of 15 seconds, or set a positive number of seconds.

at least one collector group must be enabled​

Cause

Every group under collectors is set to false.

Fix

Enable at least one of cpu, memory, system, network, disk, smb or time, or remove collectors to collect them all.

failed to open WMI session: open DCOM object resolver interface: connection refused​

When

transport: dcom

Cause

Nothing accepts connections on TCP 135 at the configured host, or a firewall rejects them.

Fix

Enable the Windows Management Instrumentation (WMI) firewall rules for the poller, as described under Prerequisites, and check that host points at the Windows host.

failed to open WMI session: open DCOM object resolver interface: could not resolve the WMI host​

When

transport: dcom

Cause

The poller cannot resolve the configured host name.

Fix

Use a name the poller resolves, such as the host's fully qualified domain name, or its IP address.

failed to open WMI session: read DCOM server version: ERROR_ACCESS_DENIED (0x00000005)​

When

transport: dcom

Cause

The host rejected the login. The username or password is wrong, or the host does not accept NTLMv2.

Fix

Check username and password, including the domain part of the username, and that the host's network security policy allows NTLMv2. The host's Security event log records each rejected login as event 4625 from the poller's address. Fix it promptly or disable the job, because every collection retries the login and counts toward account lockout.

failed to open WMI session: activate WMI: E_ACCESSDENIED (0x80070005)​

When

transport: dcom, with a non-administrator account

Cause

The account may log in but is not allowed to start WMI remotely over DCOM.

Fix

Add the account to the host's local Distributed COM Users group.

failed to open WMI session: open WMI root/cimv2 namespace: StatusAccessDenied (0x80041003)​

When

transport: dcom, with a non-administrator account

Cause

The account lacks the Enable Account or Remote Enable permission on the root\cimv2 WMI namespace.

Fix

Grant both permissions in wmimgmt.msc, as described under Prerequisites.

WMI collection did not finish within the timeout of duration​

Cause

The host did not answer in time. With DCOM, the usual cause is a firewall that allows TCP 135 but blocks the WMI service's dynamic RPC port, or a host that is not reachable at all.

Fix

Allow the poller through to the WMI service, as described under Prerequisites. If the host is reachable but slow, raise timeout.

failed to open WMI session: WinRM returned HTTP 401​

When

transport: winrm

Cause

The listener rejected the login. The username or password is wrong, or the account may not use WinRM.

Fix

Check username and password; the host's Security event log records each rejected login as event 4625 from the poller's address. Every collection retries the login and counts toward account lockout. For a non-administrator account, add it to the host's local Remote Management Users group.

failed to open WMI session: WinRM server certificate verification failed​

When

transport: winrm

Cause

The poller does not trust the listener certificate, or the certificate does not match the configured host.

Fix

Set tls_ca to the PEM file of the CA that issued the listener certificate, and set host to a name in the certificate.

failed to open WMI session: WinRM request failed: connection refused​

When

transport: winrm

Cause

Nothing accepts connections on TCP 5986 at the configured host, or a firewall rejects them.

Fix

Create the HTTPS listener and allow TCP 5986 from the poller, as described under Prerequisites.

failed to open WMI session: WinRM request failed: could not resolve the WMI host​

When

transport: winrm

Cause

The poller cannot resolve the configured host name.

Fix

Use a name the poller resolves and that matches the listener certificate, such as the host's fully qualified domain name.

ICMP ping disabled: the plugin may not open raw ICMP sockets, which on Linux requires the CAP_NET_RAW capability​

Cause

wmi.plugin lacks the CAP_NET_RAW capability on the poller, for example because the installer ran without the setcap tool or inside a container, where it does not set capabilities. The job logs this once and keeps collecting WMI metrics without ping charts.

Fix

Grant the capability, then restart the Netdata service:

sudo setcap cap_net_raw+ep /usr/libexec/netdata/plugins.d/wmi.plugin

In a container, run the same command inside it only when the container keeps cap_net_raw in its capability bounding set (capsh --print lists it under Bounding set). A binary whose file capability the container does not allow fails to start, which would stop all WMI collection.

ICMP ping failed: could not resolve the host​

Cause

The poller could not resolve the configured host name when it pinged the host, while the WMI queries of that collection succeeded. The usual cause is an intermittent DNS failure, or a DNS server that does not answer within the ping time limit of up to 3 seconds.

Fix

Use a name the poller resolves reliably, such as the host's fully qualified domain name, or its IP address.

ICMP ping failed: reason​

Cause

The poller could not send the echo requests, for example because a firewall on the poller rejects outgoing ICMP (operation not permitted) or has no route to the host (no route to host).

Fix

Allow outgoing ICMP echo requests from the poller to the host, and check the poller's routing to the host's address.

Ping packet loss stays at 100% while the other charts update​

Cause

The host, or a firewall between it and the poller, drops ICMP echo requests or their replies. Windows Firewall blocks inbound echo requests unless a rule allows them.

Fix

Allow ICMP echo requests from the poller, as described under Prerequisites. If ICMP must stay blocked, exclude the host from the ping_host_reachable alert with a chart labels line in your copy of health.d/ping.conf, for example:

chart labels: host=!fileserver.example.com *

The host's node is Stale and the wmi_host_last_collected_secs alert is critical​

Cause

The poller has missed two to three collections in a row from the host. The host is down or unreachable, or it rejects the login. The job logs the reason with every failed collection, as one of the errors above.

Fix

Fix the cause the job logs. With the next successful collection the node turns live again and the alert clears; the alert's recovery notification is delayed by at least 5 minutes.

The wmi_host_clock_offset alert is raised​

Cause

Over the last 5 minutes, the host's clock was on average more than 60 seconds ahead of or behind the poller's. The Windows Time service on the host is stopped or cannot reach its time source, or, when every host of the poller shows a similar offset, the poller's own clock is wrong.

Fix

On the host, check the time source and the last successful synchronization with w32tm /query /status, and synchronize with w32tm /resync; wmi.clock_sync_sources at 0 shows that no time source answers the Windows Time service. When every host of the poller shows a similar offset, fix the time synchronization of the poller instead.

The wmi_host_time_sources alert is raised​

Cause

No collection in the last hour counted a time server that answers the host's Windows Time service, so the host keeps time on its own clock, which drifts. Its time source cannot be resolved or reached, or the host keeps time without NTP, such as through Hyper-V time synchronization alone or as a forest-root domain controller on its own clock. The alert notifies nobody; wmi_host_clock_offset notifies when the drift grows.

Fix

On the host, check the configured time source with w32tm /query /peers and w32tm /query /status, and the Windows Time service's events in the System log, such as event 47 (no answer from the time source) and event 134 (its name cannot be resolved). A host that keeps time without NTP needs no fix.

time service WMI query failed: read WMI query results: StatusInvalidClass (0x80041010)​

When

transport: dcom; with transport: winrm the message ends in WinRM returned a WS-Management fault

Cause

The host has no Windows Time service counters, because it runs a Windows version older than Windows Server 2016. The other metric groups keep collecting.

Fix

Set time: false under collectors in the host's job.

group WMI query failed: WinRM returned a WS-Management fault​

When

transport: winrm

Cause

The listener accepted the login but refused the query, most often because the account lacks permissions on the root\cimv2 WMI namespace.

Fix

Grant Enable Account and Remote Enable on root\cimv2 in wmimgmt.msc, as described under Prerequisites.


Do you have any feedback for this page? If so, you can open a new issue on our netdata/learn repository.