1. Home
  2. Knowledge Base
  3. General Troubleshooting
  4. Troubleshooting WMI Alias Not Found Error

Troubleshooting WMI Alias Not Found Error

Windows Management Instrumentation (WMI) is the infrastructure for data management and operations on all Windows-based operating systems. Its purpose is to help administrators manage different Windows operational environments, including remote systems.

WMI Aliases

An Alias is an abstraction introduced as part of the Windows command line tool. It provides simplified keywords to execute complex queries from the command line. Aliases capture the features of a WMI class that are relevant to some specific tasks such as disk or network administration. Visit this link to know more about WMI aliases.

Troubleshooting WMI Repository

When accessing WMI local or remote data in an application or script, the user may encounter errors ranging from missing classes to access denial. These errors may also affect the HEC-RAS analysis computation with a “CPU – Alias not found” error, as shown below. For such errors, WMI troubleshooting can be performed to troubleshoot possible errors.
"CPU - Alias not found" error

Note that if WMI returns error messages, be aware that this may not only indicate problems in the WMI service or WMI providers. Failures can also originate in other parts of the operating system and emerge as errors through WMI.

To check whether the WMI service is running correctly or not, run WMI Diagnosis Utility.

If you encounter any issue with the WMI service, perform the steps given below to run the WMI diagnosis:

  1. Open the Start menu, type cmd in the search bar, and run the Command Prompt application in administrator mode.
    Command prompt administrator mode
  2. In the Command Prompt window, run the following command:
    winmgmt /verifyrepository
    Command to verify WMI repository consistency
  3. If the WMI repository is inconsistent, run the following command that will repair the WMI repository:
    winmgmt /salvagerepository
  4. Run the following command again to verify that the WMI repository has been repaired successfully:
    winmgmt /verifyrepository

If the WMI repository does not self-correct even after performing Step 3 and Step 4, the user has to rebuild the entire WMI repository from scratch.

Follow the steps given below to rebuild the entire WMI repository:

  1. Run the Command Prompt application in administrator mode.
  2. In the Command Prompt window, run the following command to disable/stop the WMI service:
    net stop winmgmt
    Command to stop/start WMI service
  3. Then, from the Windows C drive, navigate to the following path and remove or rename the Repository folder:
    C:\Windows\System32\wbem\Repository
    Rename WMI "Repository" folder
  4. From the Command Prompt window, navigate to the wbem folder using the following command:
    cd C:\Windows\System32\wbem
    Navigate renamed repository folder using command prompt
  5. Then, run the following command:
    for /f %s in (‘dir /b *.mof’) do mofcomp %s
    Data storing in repository folder
  6. Finally, run the following command:
    for /f %s in (‘dir /b en-us\*.mfl’) do mofcomp en-us\%s
    Data storing in repository folder
  7. After the successful completion of the process, Done! will be displayed.
  8. Now, restart the PC and the changes will take effect.

About the Author cxscvlgeo

  • Was this helpful?
  • YesNo

Was this article helpful?

Related Articles