Nagios WMI 1 – Installing The WMI Client
Adding WMI To The Linux Host
The first step in configuring Nagios to monitor a Remote Windows Server through WMI is to install the WMI client. The following sections provide details on how to add the Atomic Repository, install the WMI client, and finally test that it is working and communicating with the Windows Server.
Adding The Atomic Repository
The first part of installing the WMI client on to the server is to add the Atomic repository repository to the server. To add the Atomic repository to the server perform the following steps :-
- In the command line execute the following command :-
wget -q -O – http://www.atomicorp.com/installers/atomic | sh
- When prompted accept the agreement
- When prompted select OK to install the package
Installing The WMI Client
The next part is to install the WMI client package from the Atomic Repository and to do this perform the step below :-
- In the command prompt execute the following command :-
yum install wmi
- When prompted select OK to install the package
Testing The WMI Client
To test that the WMI client is installed and working perform the following steps :-
- In the command prompt execute the following command :-
wmic -U {Domain Name}/{Admin User}%{Admin Password //{Host} “select * from Win32_ComputerSystem”
E.G. wmic -U Example/Administrator%password //examplehost “select * from Win32_ComputerSystem”
- Replace the {Domain Name}. {Admin User}, {Admin Password}, and {Host} with your relevant settings
- The command will return a list of WMI information it can enumerate from the Win32_ComputerSystem Class on the host server.