Created
May 30, 2017 18:39
-
-
Save p0rkjello/3a0a9f64fac3bc3aa9bdfabdad64d10a to your computer and use it in GitHub Desktop.
Reregister WMI DLL's and rebuild MOF files.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
:: https://blogs.technet.microsoft.com/askperf/2009/04/13/wmi-rebuilding-the-wmi-repository/ | |
sc config winmgmt start= disabled | |
net stop winmgmt /y | |
%systemdrive% | |
cd %windir%\system32\wbem | |
for /f %%s in ('dir /b *.dll') do regsvr32 /s %%s | |
wmiprvse /regserver | |
winmgmt /regserver | |
sc config winmgmt start= auto | |
net start winmgmt | |
for /f %%s in ('dir /s /b *.mof *.mfl') do mofcomp %%s |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment