What is this?

This knowledgebase contains questions and answers about PRTG Network Monitor and network monitoring in general.

Learn more

PRTG Network Monitor

Intuitive to Use. Easy to manage.
More than 500,000 users rely on Paessler PRTG every day. Find out how you can reduce cost, increase QoS and ease planning, as well.

Free Download

Top Tags

View all Tags

WMI error with custom sensor




I tried to create custom wmi counter with using your wmitester utility. The query is

SELECT RecoverPercentage  FROM Win32_PerfFormattedData_DcsHa_DataCoreMirroring WHERE Name='_Total'

With the wmitester I receive a positive result. So I created a wql file with the syntax as above and created a sensor. When I start the sensor I receive an error:

80041017: The query was not syntactically valid.

After several tries accidently a similar sensor suddenly worked. Any ideas?

Regards, Christian Harmeling

custom error wmi

Created on Nov 11, 2010 11:24:52 AM

Last change on Nov 11, 2010 11:57:50 AM by  Daniel Zobel [Product Manager]

3 Replies



Sorry, we can only blind-guess, too, what's going on behind the scenes of WMI. Syntactically invalid means that either one or more keywords are erroneous (that's the easy case, but unfortunately not the case with your query) or that one or more of the selected or where'd fields are not included/visible in the WMI class on the host computer. This can be because of timing issues or accessibility rights somewhere in the DCOM/WMI structures...

Kind regards, - Volker

Created on Nov 16, 2010 1:33:04 PM by  Volker Uffelmann [Paessler Support]



Now I discovered a reproducable hint: I tried to test my custom wmi sensor on the system where prtg is installed with wmitester which also failed with the error I mentioned above. As I wrote I tested with wmitester succesfully before - but - that was on my laptop.

I now installed prtg on my laptop, created the same custom sensors - and it works w/o problems.

There seems to be some special circumstance on my server (which in fact is another laptop :-)), both laptops have Windows 7 Enterprise installed as OS, the server being in the same domain as the tested system, my laptop being in another domain.

Regards, Christian

Created on Dec 11, 2010 3:31:03 PM



If I understand you correctly, your non-domain computer is able to see the WQL field whereas the domain computer is not? That's remarkable because usually it's exactly the other way round.

As for the cause for this: You will find hints in the settings of DCOM/WMI and/or domain policies. Unfortunately, I can't tell which ones, however.

Kind regards, - Volker

Created on Dec 14, 2010 12:58:59 PM by  Volker Uffelmann [Paessler Support]

Last change on Dec 14, 2010 1:31:57 PM by  Daniel Zobel [Product Manager]

Disclaimer: The information in the Paessler Knowledge Base comes without warranty of any kind. Use at your own risk. Before applying any instructions please exercise proper system administrator housekeeping. You must make sure that a proper backup of all your data is available.