- 09 Jan 2023
- 1 Minute to read
- Print
- DarkLight
- PDF
Fixing WMI Corruption in a Windows Server
- Updated on 09 Jan 2023
- 1 Minute to read
- Print
- DarkLight
- PDF
If you've determined that the WMI repository or other system files in your Windows server are corrupt, you (or your Windows administrator) can try the following steps (in order) to resolve the problem. Remember to test at the appropriate points to avoid performing unnecessary steps.
Begin by attempting to salvage and reset the WBEM repository.
Step 1.
Disable and stop the WMI service. (Note that there is an empty space between "=" and "disabled")
sc config winmgmt start= disabled net stop winmgmt
Step 2.
Run the following commands:
winmgmt /salvagerepository %windir%\System32\wbem winmgmt /resetrepository %windir%\System32\wbem
Step 3.
Re-enable the WMI service and then reboot the server. (Note that there is an empty space between "=" and "auto")
sc config winmgmt start= auto
Check to see if this resolves the issue. If so, you're done.
If the problem still occurs, try the following steps to rebuild the repository.
Step 4.
Disable and stop the WMI service. (Note that there is an empty space between "=" and "disabled".)
sc config winmgmt start= disabled net stop winmgmt
Step 5.
Rename the repository folder (located at %windir%\System32\wbem\repository
) to "repository.old".
Step 6.
Re-enable the WMI service. (Note that there is an empty space between "=" and "auto".)
sc config winmgmt start= auto
Step 7.
Reboot the server and try again. You may need to rejoin the server to the domain.
Check to see if this resolves the issue.
If the problem still occurs:
Step 8.
Try restoring the server from a recent backup.
Check to see if this resolves the issue. If so, you're done.
If you have tried all these methods and the problem is still occurring, you may have some disk sectors or system files that are corrupted.
Step 9.
Try the following commands to see if they can fix the corrupted files/sectors.
chkdsk sfc /scannow
If none of these resolve the problem, you may need to reinstall the Windows server. Please contact Netreo support if you require additional assistance.