Install SQL SERVER prompt for WMI service failure workaround

Source: Internet
Author: User
Tags goto

1. Cause: The WMI service is corrupt.

2. WORKAROUND: Run the batch statement as an administrator.

@echo on
CD/D C:\Temp
If not exist%windir%\System32\Wbem goto Tryinstall
CD/D%windir%\System32\Wbem
net stop WinMgmt
Winmgmt/kill
If exist Rep_bak Rd REP_BAK/S/q
Rename Repository Rep_bak
For%%i in (*.dll) do regsvr32-s%%i
For%%i in (*.exe) do call:fixsrv%%i
For%%i in (*.MOF,*.MFL) do mofcomp%%i
net start WinMgmt
Goto END

: Fixsrv
if/i (% 1) = = (Wbemcntl.exe) goto SKIPSRV
if/i (% 1) = = (Wbemtest.exe) goto SKIPSRV
if/i (% 1) = = (mofcomp.exe) goto SKIPSRV
%1/regserver

: Skipsrv
Goto END

: Tryinstall
If not exist Wmicore.exe goto END
wmicore/s
net start WinMgmt
: End

Install SQL SERVER prompt for WMI service failure workaround

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.