check_wmi_plus checkservice not working
-
slocrystal
- Posts: 17
- Joined: Wed Jun 29, 2011 5:25 pm
check_wmi_plus checkservice not working
I am not sure if I am using the checkservice correcly but I am getting the following response.
"UNKNOWN - The WMI query had problems. The target host (192.168.10.75) might not have the required WMI classes installed. This can happen, for example, if you are trying to checkiis but IIS is not installed. It can also happen if your version of Windows do"
I have the check setup as
./check_wmi_plus.pl -H HOSTADDRESS -u user -p password -m checkserivce "servicename"
Any ideas, the other services like checkcpu etc work fine.
Thanks.
"UNKNOWN - The WMI query had problems. The target host (192.168.10.75) might not have the required WMI classes installed. This can happen, for example, if you are trying to checkiis but IIS is not installed. It can also happen if your version of Windows do"
I have the check setup as
./check_wmi_plus.pl -H HOSTADDRESS -u user -p password -m checkserivce "servicename"
Any ideas, the other services like checkcpu etc work fine.
Thanks.
Re: check_wmi_plus checkservice not working
Can you try adding an "- a" flag to your command and wrapping the servicename is single quotes?
You also had a typo in "checkservice" - not sure if you used the same command in your check or made a mistake while typing your post.
P.S. Make sure you use a correct servicename.
Hope this helps.
Code: Select all
./check_wmi_plus.pl -H HOSTADDRESS -u user -p password -m checkservice -a 'servicename'P.S. Make sure you use a correct servicename.
Hope this helps.
Be sure to check out our Knowledgebase for helpful articles and solutions!
-
slocrystal
- Posts: 17
- Joined: Wed Jun 29, 2011 5:25 pm
Re: check_wmi_plus checkservice not working
I receive the same error with the -a. The service name I had already been wrapping in single quotes. It is stating in the longer description that it's possible that the class is not on the destination machine. The machine I am trying to check the service on is a server core 2008 install.
Re: check_wmi_plus checkservice not working
which service are you trying to check?
Try the cpu service check for example:
check_wmi_plus.pl -H HOST -u USER -p PASS -m checkcpu
Here's a list of some usefull examples to try:
http://www.edcint.co.nz/checkwmiplus/?q=node/57
Try the cpu service check for example:
check_wmi_plus.pl -H HOST -u USER -p PASS -m checkcpu
Here's a list of some usefull examples to try:
http://www.edcint.co.nz/checkwmiplus/?q=node/57
-
slocrystal
- Posts: 17
- Joined: Wed Jun 29, 2011 5:25 pm
Re: check_wmi_plus checkservice not working
I am able to use the checkcpu and some of the others without issue. The one I am trying to do is the actual "checkservice" The example from the link you gave me is as follows:
Check all services with the string 'windows' in the short or long name
Command: check_wmi_plus.pl -H HOST -u USER -p PASS -m checkservice -a windows
When I put in my host ip, username and password (same as I use for my other working checks) and then add my service name or a portion of the service name both in single quotes or without quotes I get the same error:
"UNKNOWN - The WMI query had problems. The target host (IP of host) might not have the required WMI classes installed. This can happen, for example, if you are trying to checkiis but IIS is not installed. It can also happen if your version of Windows does not support this check (this might be because the WMI fields are named differently in different Windows versions). Sometimes, some systems 'lose' WMI Classes and you might need to rebuild your WMI repository. Other causes include mistyping the WMI namespace/class/fieldnames. There may be other causes as well. You can use wmic from the command line to troubleshoot. Wmic error text on the next line.
ERROR: Retireve result data.
NTSTATUS: NT code 0xc0041003 - NT code 0xc0041003"
I will dig around in the WMI on my server core machine to see if maybe they changed the name of that check?
Check all services with the string 'windows' in the short or long name
Command: check_wmi_plus.pl -H HOST -u USER -p PASS -m checkservice -a windows
When I put in my host ip, username and password (same as I use for my other working checks) and then add my service name or a portion of the service name both in single quotes or without quotes I get the same error:
"UNKNOWN - The WMI query had problems. The target host (IP of host) might not have the required WMI classes installed. This can happen, for example, if you are trying to checkiis but IIS is not installed. It can also happen if your version of Windows does not support this check (this might be because the WMI fields are named differently in different Windows versions). Sometimes, some systems 'lose' WMI Classes and you might need to rebuild your WMI repository. Other causes include mistyping the WMI namespace/class/fieldnames. There may be other causes as well. You can use wmic from the command line to troubleshoot. Wmic error text on the next line.
ERROR: Retireve result data.
NTSTATUS: NT code 0xc0041003 - NT code 0xc0041003"
I will dig around in the WMI on my server core machine to see if maybe they changed the name of that check?
Re: check_wmi_plus checkservice not working
Make sure the "checkservice" is the proper name to be used. Check for spaces, etc. It has to be exact, for example "ProtectedStorage" is not the same as "Protected Storage".
Be sure to check out our Knowledgebase for helpful articles and solutions!
-
slocrystal
- Posts: 17
- Joined: Wed Jun 29, 2011 5:25 pm
Re: check_wmi_plus checkservice not working
I changed the checkservice to CheckService and now I get a message that says "A valid MODE and/or SUBMODE must be specified"
Re: check_wmi_plus checkservice not working
Try to follow the steps outlined here:
http://edcint.co.nz/checkwmiplus/?q=node/55
Let us know if this helped.
http://edcint.co.nz/checkwmiplus/?q=node/55
Let us know if this helped.
Be sure to check out our Knowledgebase for helpful articles and solutions!
-
slocrystal
- Posts: 17
- Joined: Wed Jun 29, 2011 5:25 pm
Re: check_wmi_plus checkservice not working
The ini file seems to be the same and the plugin is the latest.
Re: check_wmi_plus checkservice not working
What is the output when you run in terminal:
I found a Matthew Jurgens' post, concerning a similar issue: "using versions of perl modules older than the recommended ones was the cause of the problem - specifically Config::Inifiles." I am not sure if your issue is caused by an old perl modules, but you can try:
and then upgrade the installed package:
Code: Select all
./check_wmi_plus.pl -H <IP> -u <username> -p <password> -m checkservice -a 'windows'Code: Select all
# yum list installed perl-Config-IniFilesCode: Select all
# yum upgrade <your_perl_config-inifiles_package>Be sure to check out our Knowledgebase for helpful articles and solutions!