Initialization failure: WMI provider and SQL Server 2005
Ever open up the SQL Server Configuration Manager and receive this message?
I have; and an initial google search bring up a bevy of solutions. Unfortunately, the first several offerings did not solve my problem -- which prompted me to dig a little deeper.
Apparently, I had corrupted my WMI repository somewhere along the line; and after some reading, the WMI can be corrupted after multiple restores of a database... which I'm definitely guilty of. So the solution? rebuild the WMI. Piece of cake, right? Luckily, I stumbled across this blog link which detail these instructions (which can be batched into a .bat file):
net stop winmgmt
c:
cd %systemroot%\system32\wbem
rd /S /Q repository
regsvr32 /s %systemroot%\system32\scecli.dll
regsvr32 /s %systemroot%\system32\userenv.dll
mofcomp cimwin32.mof
mofcomp cimwin32.mfl
mofcomp rsop.mof
mofcomp rsop.mfl
for /f %%s in ('dir /b /s *.dll') do regsvr32 /s %%s
for /f %%s in ('dir /b *.mof') do mofcomp %%s
for /f %%s in ('dir /b *.mfl') do mofcomp %%s
echo DONE reboot
pause
Ottimo! Everything should work. But not so fast, this message appears the next time I try to start up the SQL Server Configuration Manager:
"Cannot connect to WMI provider. You do not have permission or the server is unreachable. Note that you can only manage SQL Server 2005 servers with SQL Server Configuration Manager. Invalid class [0x80041010]"
Motherfunbag. I guess that didn't do it. Opening the command prompt and typing the below addresses this and ultimately fixes my issue:
C:\Program Files\Microsoft SQL Server\90\Shared>mofcomp "C:\Program Files\Microsoft SQL Server\90\Shared\sqlmgmproviderxpsp2up.mof" Microsoft (R) 32-bit MOF Compiler Version 5.1.2600.2180 Copyright (c) Microsoft Corp. 1997-2001. All rights reserved. Parsing MOF file: C:\Program Files\Microsoft SQL Server\90\Shared\sqlmgmprovider xpsp2up.mof MOF file has been successfully parsed Storing data in the repository... Done!

0 Comments