How to repair WMIC?

If you are facing the error "Unable to fetch machine details. The WMIC of this machine might be corrupted, this can be resolved by repairing the WMIC." during registration or login, follow these steps to confirm and repair the WMIC of the system.

Steps to repair a system's corrupted WMIC

  • In start menu enter "cmd" to open Command Prompt as Administrator.
  • Type "net stop winmgmt" and press Enter
  • Open a Windows Explorer and locate the path to C:windowssystem32WBEM folder and rename the Repository folder to something else like RepositoryOLD (right click and choose 'Rename Folder').
  • Restart the computer.
  • In the start menu enter "cmd" to open Command Prompt.
  • Type "net stop winmgmt" and press enter
  • Type "winmgmt/resetRepository" and restart the computer.

To confirm whether the "invalid class" error is thrown from Windows or from app

  • Click Start, click Run, type wmimgmt.msc, and then click OK.
  • Right-click WMI Control (Local), and then click Properties.
  • If you see Invalid class error, then it is thrown from Windows class itself. Solution is to repair WMIC.
Last modified ago