PowerTip: Use PowerShell to List Top-Level WMI Namespaces

Summary: Use Windows PowerShell to list top-level WMI namespaces.

Hey, Scripting Guy! Question How can I use Windows PowerShell to list the top-level WMI namespaces?

Hey, Scripting Guy! AnswerUse the Get-WmiObject cmdlet or the Get-CImInstance cmdlet and query for __NameSpace:

Windows PowerShell 2.0 syntax:

Get-WmiObject __NameSpace | select name


Windows PowerShell 3.0 syntax:

Get-CimInstance __NameSpace | select name

Comments (1)

  1. sunny says:

    I believe this gives a better output

    Get-WmiObject -Namespace root -class __NameSpace | Select Name

Skip to main content