Running into an issue where some of our servers with multiple NICs have the same adapter name. Since check_wmi_plus shows duplicate names, how does it differentiate which is which? or is there an argument I can use here?
Checknetwork results of adapters:
Valid Adapter Names are:
Broadcom BCM5709C NetXtreme II GigE [NDIS VBD Client]
Broadcom BCM5708C NetXtreme II GigE [NDIS VBD Client]
Broadcom BCM5708C NetXtreme II GigE [NDIS VBD Client] _2
but using powershell, we can see the adapter details.
Description Index
----------- -----
Broadcom BCM5709C NetXtreme II GigE (NDIS VBD Client) 7
Broadcom BCM5708C NetXtreme II GigE (NDIS VBD Client) 15
Broadcom BCM5708C NetXtreme II GigE (NDIS VBD Client) #2 16
Duplicate WMI network adapter names
Re: Duplicate WMI network adapter names
Try adding the -a option on to the command, that will give a detailed listing:
Also, from the --help:
Code: Select all
./check_wmi_plus.pl -H X.X.X.X -u USER -p PASS -m checknetwork -achecknetwork
These network checks use WMI Raw counters to calculate values over a given timeperiod.
This is much more accurate than taking Formatted WMI values.
ARG1 Specify the network interface the stats are collected for. If set to . all interfaces will be included.
To include multiple interfaces separate them with a | or specify a common identifier eg part of an IP Address or MAC Address. This uses a regular expression so take care to
specify exactly what you want. eg "LAN0" or "192.168.0.1" or "192.168.0" or "LAN0|LAN2" or "." or "08:00:27:85:CE:6D" or "08:00:27"
To specify a network interface you can use either the Connection Name (as seen in Control Panel), IP Address (IPv4 or IPV6) or MAC Address. You can also use the name of the network adaptors as seen from WMI which is similar to what is seen in the output of the ipconfig/all command on Windows. However, it is not exactly the same and can be tricky since this uses a regular expression. Run without -a to show the interface
names, IP Addresses, MAC Addresses. Typically you need to use '' around the adapter name when specifying.
-
CFT6Server
- Posts: 506
- Joined: Wed Apr 15, 2015 4:21 pm
Re: Duplicate WMI network adapter names
The output I provided was with the -a option. Looks my version of check_wmi_plus had to be upgraded. I am using 2.6 XI which had 1.49 and the current version is 1.60. It took a bit of tweaking but got it working now. With the newer version, it supports multiple options the identify the NIC. I am using MAC address as that seems to work best.
Re: Duplicate WMI network adapter names
Glad to see this is working based on MAC. I will now close this thread out, but feel free to open another one if you ever need assistance!
Former Nagios Employee