0
On a Windows Server 2008 R2 Datacenter (Service Pack) I am trying to query the following counters, but getting the error 'Invalid Query' in wbemtest.exe
Win32_PerfRawData_PerfOS_Memory
Win32_PerfRawData_PerfOS_Processor
They are not even turning up in the list of objects! I am new to this, so my apologies if you feel there is information missing. I will make it available as the questions arrive.
The result of:
Get-WmiObject -Query "Select * from Win32_PerfRawData_PerfOS_Memory"
is as follows:
Get-WmiObject : Invalid query "Select * from Win32_PerfRawData_PerfOS_Memory"
At line:1 char:1
+ Get-WmiObject
+ ~~~~~~~~~~~~~
+ CategoryInfo : InvalidArgument: (:) [Get-WmiObject], ManagementException
+ FullyQualifiedErrorId : GetWMIManagementException,Microsoft.PowerShell.Commands.GetWmiObjectCommand
Which version of Windows are you using? What's the actual query you are putting using wbemtest? If you're on a recent Windows, open a PowerShell prompt "as administrator", and run
Get-WmiObject -Query "Select * from Win32_PerfRawData_PerfOS_Memory"
-- does that work? – Ƭᴇcʜιᴇ007 – 2016-02-05T13:36:29.917