Table of Contents |
---|
Overview
In NMIS version 8.6.0 we've added support for collecting data from Windows systems using the Windows Management Instrumentation infrastructure (or WMI for short WMI)). As of NMIS9 support for domains has been enhanced to make it easier to configure.
This this page describes how to approach modelling devices for WMI, and where WMI modelling differs from modelling for SNMP.
...
To collect WMI data NMIS has to use a WMI access tool. At As of NMIS 8.6.0 we are using wmic
, a commandline tool belonging to the Samba software suite.
NMIS 8.6.0 ships with a precompiled wmic
program, and installs it as /usr/local/nmis8/bin/wmic
. If the precompiled version should not work on your platform, the installer will notify you of that problem and you'll have to perform a manual build of wmic
. The sources for wmic
can be downloaded here: http://dl-nmis.opmantek.com/wmic-omk.tgz and you shouldn't have to do more than unpack that, and run make
. When the build is complete, you should copy the resulting wmic
file to /usr/local/nmis8/bin/
.
...
If the node in question requires a windows domain prefix for the WMI access, then In NMIS 8 prepend that to the wmiusername
followed by a "/", e.g. "somedomain/theuser
". In NMIS 8.6.7 and newer you can also provide the domain in the form "theuser@somedomain
".
In NMIS9, in addition to the NMIS8 syntax, there is a dedicated 'WMI Domain' field to make configuration easier.
Automatic model selection does include WMI as a source of information, if SNMP is not available and if wmiusername
and wmipassword
are set. Automatic Model selection in NMIS uses the device property "sysDescr" (an SNMP property) for WMI only devices the sysDescr is auto created from the WMI received variables "winosname" and "winversion" e.g getNodeInfo, winosname=Microsoft Windows Server 2016 Datacenter winversion=10.0.14393 this string is then interpreted to sysDescr as Microsoft Windows Server 2016 Datacenter Windows Version 10.0.14393.
Modelling Preparation
We recommend that you verify the availability of WMI (and your credentials) with wmic
, before performing any modelling work. This should be done using the wmic
tool on your NMIS server, like in the following example:
...
Besides using the standard Widows models that NMIS ships with as examples, you will likely also need to consult the online WMI reference documentation for determining what is available in the WMI universe where and how to tell NMIS about it.
WMI Troubleshooting
The wmic client will accept a user in the following format:
- domain/username
- username@domain
- username
In the inside, NMIS calls the windows wmic client using the following parameters:
Code Block |
---|
/usr/local/nmis8/bin/wmic --delimiter=rvqbfzsfzd -A /tmp/authfile //HOST_IP "select * from win32_operatingsystem" |
To test this exactly command, a file /tmp/authfile with the following information is needed (and for NMIS9, 'domain = domain
' is supported as well):
Code Block |
---|
username = user
password = name |
We should not expect the same data as the one collect by SNMP. WMI can work without snmp, but WMI data structure is different. We should probably expect data in the interfaces, system and systemHealth sections.
Even though, the model should be discovered automatically, the same as in SNMP.
More info - Using WMI to query and monitor Windows devices
More WMI troubleshooting documentation can be found here
WMI Modelling in a nutshell
Let's examine an example model:
...
- It is not possible for a
systemHealth
section to have bothsnmp
andwmi
sections.
This is because only one index persystemHealth
section is supported, butwmi
andsnmp
can not share that single index. - At this time, collection of the following types of statistics from WMI is not supported:
Network Interfaces
Environment Data
CBQoS Data
Calls
Server-type processor and load information - NMIS does not yet support service tests for WMI-sourced process information.
- Collection of indexed WMI sections is not optimised for maximum efficiency yet.
query results are reused to some extent but not universally, and further optimisations are planned. - The GUI model editor does not support editing of WMI sections yet.
...