0

I use WBEMTEST.exe to test WMI on Windows Server 2012 R2. DHCP feature on this windows is installed and DHCP Server have a scope.

Image of DHCP Scope

Step 1 : Open WBEMTEST.exe and connected to "root\microsoft\windows\dhcp" namespace.

Image of namespace connected

Step 2 : Sended this "SELECT * from PS_DhcpServerv4Scope" query.

Image of query

After all of this, WBEMTEST not returning any data of DHCP Server Scope.

Image of result

I test all steps on Windows Server 2016 but WBEMTEST not returning any data too.

What was my mistake? Can anybody help me?

M. Rostami
  • 127
  • 1
  • 2
  • 13
  • The result of the query itself is empty, what do you expect? It doesn't even have any properties in this context. Try to expand the content of the Class (demo in PS): `(Get-WmiObject -ComputerName -Namespace ROOT\Microsoft\Windows\DHCP -List | Where-Object Name -eq 'PS_DhcpServerv4Scope').Get() | Select-Object -ExpandProperty cmdletOutput` – bjoster Feb 07 '18 at 14:19
  • Opps, yes. I test your command and PS gave some result. I try "DhcpServerv4Scope" in WBEM but not returning any data. What do i do? – M. Rostami Feb 07 '18 at 20:57
  • What do you *want* to do? The object DhcpServerv4Scope is empty, so nothing is returned. But that class has some properties (which has some data). If you want to list those, click list, then open. There is no (known to me) WMI select command to list a classe's classes (and properties), so you have to use PS or VBS. Have a look at this article from the scripting guy: https://technet.microsoft.com/de-de/library/ee692770.aspx – bjoster Feb 13 '18 at 10:22

0 Answers0