Page 1 of 8 123 ... LastLast
    Windows Update - Reset in Windows 10

    Windows Update - Reset in Windows 10

    How to Reset Windows Update in Windows 10
    Published by
    2015-10-01
    Designer Media Ltd

    Published by


    Brink's Avatar
    Administrator

    Posts: 16,449

    Show Printable Version 


    How to Reset Windows Update in Windows 10

    information   Information
    Windows Update keeps Windows 10 updated by downloading and installing the latest updates, drivers, and hotfixes released by Microsoft.

    Sometimes you may have an issue with Windows Update such as not being able to download or install updates, error messages, not being able to search for new updates, etc. These kind of issues can occur when the Windows Update database or components are corrupted, one or more services related to Windows Update are not running, etc.

    Resetting the Windows Update components and history can usually solve these types of issues.

    This tutorial will show you how to completely reset and reregister Windows Update components and history in Windows 10.

    You must be signed in as an administrator to be able to reset Windows Update.


    EXAMPLE: Update history before and after reset
    Click image for larger version. 

Name:	Windows_Update_history.png 
Views:	2607 
Size:	78.8 KB 
ID:	40499





    Here's How:
    Note   Note
    The downloadable .bat file below contains these commands that will reset Windows Update.

    Code:
    @echo off
    
    :: Created by: Shawn Brink
    :: Created on: October 1st 2015
    :: Updated on: October 18th 2016
    :: Tutorial: http://www.tenforums.com/tutorials/24742-windows-update-reset-windows-10-a.html
    
    
    set b=0
    
    :bits
    set /a b=%b%+1
    if %b% equ 3 (
       goto end1
    ) 
    net stop bits
    echo Checking the bits service status.
    sc query bits | findstr /I /C:"STOPPED" 
    if not %errorlevel%==0 ( 
        goto bits 
    ) 
    goto loop2
    
    :end1
    cls
    echo.
    echo Cannot reset Windows Update since "Background Intelligent Transfer Service" (bits) service failed to stop.
    echo.
    pause
    goto Start
    
    
    :loop2
    set w=0
    
    :wuauserv
    set /a w=%w%+1
    if %w% equ 3 (
       goto end2
    ) 
    net stop wuauserv
    echo Checking the wuauserv service status.
    sc query wuauserv | findstr /I /C:"STOPPED" 
    if not %errorlevel%==0 ( 
        goto wuauserv 
    ) 
    goto loop3
    
    :end2
    cls
    echo.
    echo Cannot reset Windows Update since "Windows Update" (wuauserv) service failed to stop.
    echo.
    pause
    goto Start
    
    
    
    :loop3
    set app=0
    
    :appidsvc
    set /a app=%app%+1
    if %app% equ 3 (
       goto end3
    ) 
    net stop appidsvc
    echo Checking the appidsvc service status.
    sc query appidsvc | findstr /I /C:"STOPPED" 
    if not %errorlevel%==0 ( 
        goto appidsvc 
    ) 
    goto loop4
    
    :end3
    cls
    echo.
    echo Cannot reset Windows Update since "Application Identity" (appidsvc) service failed to stop.
    echo.
    pause
    goto Start
    
    
    :loop4
    set c=0
    
    :cryptsvc
    set /a c=%c%+1
    if %c% equ 3 (
       goto end4
    ) 
    net stop cryptsvc
    echo Checking the cryptsvc service status.
    sc query cryptsvc | findstr /I /C:"STOPPED" 
    if not %errorlevel%==0 ( 
        goto cryptsvc 
    ) 
    goto Reset
    
    :end4
    cls
    echo.
    echo Cannot reset Windows Update since "Cryptographic Services" (cryptsvc) service failed to stop.
    echo.
    pause
    goto Start
    
    
    :Reset
    Ipconfig /flushdns
    del /s /q /f "%ALLUSERSPROFILE%\Application Data\Microsoft\Network\Downloader\qmgr*.dat" 
    del /s /q /f "%ALLUSERSPROFILE%\Microsoft\Network\Downloader\qmgr*.dat"
    del /s /q /f "%SYSTEMROOT%\Logs\WindowsUpdate\*"
    
    
    if exist "%SYSTEMROOT%\winsxs\pending.xml.bak" del /s /q /f "%SYSTEMROOT%\winsxs\pending.xml.bak" 
    if exist "%SYSTEMROOT%\winsxs\pending.xml" ( 
        takeown /f "%SYSTEMROOT%\winsxs\pending.xml" 
        attrib -r -s -h /s /d "%SYSTEMROOT%\winsxs\pending.xml" 
        ren "%SYSTEMROOT%\winsxs\pending.xml" pending.xml.bak 
    ) 
      
    if exist "%SYSTEMROOT%\SoftwareDistribution.bak" rmdir /s /q "%SYSTEMROOT%\SoftwareDistribution.bak"
    if exist "%SYSTEMROOT%\SoftwareDistribution" ( 
        attrib -r -s -h /s /d "%SYSTEMROOT%\SoftwareDistribution" 
        ren "%SYSTEMROOT%\SoftwareDistribution" SoftwareDistribution.bak 
    ) 
     
    if exist "%SYSTEMROOT%\system32\Catroot2.bak" rmdir /s /q "%SYSTEMROOT%\system32\Catroot2.bak" 
    if exist "%SYSTEMROOT%\system32\Catroot2" ( 
        attrib -r -s -h /s /d "%SYSTEMROOT%\system32\Catroot2" 
        ren "%SYSTEMROOT%\system32\Catroot2" Catroot2.bak 
    ) 
      
      
    sc.exe sdset bits D:(A;;CCLCSWRPWPDTLOCRRC;;;SY)(A;;CCDCLCSWRPWPDTLOCRSDRCWDWO;;;BA)(A;;CCLCSWLOCRRC;;;AU)(A;;CCLCSWRPWPDTLOCRRC;;;PU)
    
    sc.exe sdset wuauserv D:(A;;CCLCSWRPWPDTLOCRRC;;;SY)(A;;CCDCLCSWRPWPDTLOCRSDRCWDWO;;;BA)(A;;CCLCSWLOCRRC;;;AU)(A;;CCLCSWRPWPDTLOCRRC;;;PU)
    
    cd /d %windir%\system32
    
    regsvr32.exe /s atl.dll 
    regsvr32.exe /s urlmon.dll 
    regsvr32.exe /s mshtml.dll 
    regsvr32.exe /s shdocvw.dll 
    regsvr32.exe /s browseui.dll 
    regsvr32.exe /s jscript.dll 
    regsvr32.exe /s vbscript.dll 
    regsvr32.exe /s scrrun.dll 
    regsvr32.exe /s msxml.dll 
    regsvr32.exe /s msxml3.dll 
    regsvr32.exe /s msxml6.dll 
    regsvr32.exe /s actxprxy.dll 
    regsvr32.exe /s softpub.dll 
    regsvr32.exe /s wintrust.dll 
    regsvr32.exe /s dssenh.dll 
    regsvr32.exe /s rsaenh.dll 
    regsvr32.exe /s gpkcsp.dll 
    regsvr32.exe /s sccbase.dll 
    regsvr32.exe /s slbcsp.dll 
    regsvr32.exe /s cryptdlg.dll 
    regsvr32.exe /s oleaut32.dll 
    regsvr32.exe /s ole32.dll 
    regsvr32.exe /s shell32.dll 
    regsvr32.exe /s initpki.dll 
    regsvr32.exe /s wuapi.dll 
    regsvr32.exe /s wuaueng.dll 
    regsvr32.exe /s wuaueng1.dll 
    regsvr32.exe /s wucltui.dll 
    regsvr32.exe /s wups.dll 
    regsvr32.exe /s wups2.dll 
    regsvr32.exe /s wuweb.dll 
    regsvr32.exe /s qmgr.dll 
    regsvr32.exe /s qmgrprxy.dll 
    regsvr32.exe /s wucltux.dll 
    regsvr32.exe /s muweb.dll 
    regsvr32.exe /s wuwebv.dll
    regsvr32.exe /s wudriver.dll
    netsh winsock reset
    netsh winsock reset proxy
    
    :Start
    net start bits
    net start wuauserv
    net start appidsvc
    net start cryptsvc


    1. Click/tap on the Download button below to download the .bat file below.

    Reset_Reregister_Windows_Update_Components.bat

    download

    2. Save the .bat file to your desktop.

    3. Unblock the .bat file.

    4. Right click or press and hold on the .bat file, and click/tap on Run as administrator.

    5. If prompted by UAC, click/tap on Yes to approve.

    6. When finished, restart the computer to apply.

    Note   Note
    If a service fails to stop after 3 attempts, the .bat file will automatically end with a "Failed to reset Windows Update" message and prompt to press a key to continue.

    When a key is pressed, the .bat file will then restart ay service it had stopped before closing the command prompt.






    That's it,
    Shawn



  1. Join Date : Sep 2015
    Posts : 30
    Win 10 Pro x64
       2015-10-19 #1

    Thanks a lot, Brink, for this one !
    Very useful as, due to the new layout in Win 10, the overview of the history becomes quickly unbearable. This way, we can clean it up from time to time ...
      My System SpecsSystem Spec


  2. Join Date : Oct 2013
    Posts : 16,449
    64-bit Windows 10 Pro build 14971
       2015-10-19 #2

    I'm glad it could help throkr.
      My System SpecsSystem Spec


  3. Join Date : Oct 2015
    Chandigarh,India
    Posts : 306
    Windows 10
       2015-11-18 #3

    Shawn, does the script work for windows 7 or Windows 8.X
    I am concerned with the DLL's which might not be present in windows 7 or 8.
      My System SpecsSystem Spec


  4. Join Date : Oct 2013
    Posts : 16,449
    64-bit Windows 10 Pro build 14971
       2015-11-18 #4

    Sumitdhiman said: View Post
    Shawn, does the script work for windows 7 or Windows 8.X
    I am concerned with the DLL's which might not be present in windows 7 or 8.
    Hello Sumitdhiman,

    It would be recommended to use the one below for Windows 7/8 instead.

    Windows Update - Reset - Windows 7 Help Forums
      My System SpecsSystem Spec


  5. Join Date : Oct 2015
    Chandigarh,India
    Posts : 306
    Windows 10
       2015-11-18 #5

    Brink said: View Post
    Hello Sumitdhiman,

    It would be recommended to use the one below for Windows 7/8 instead.

    Windows Update - Reset - Windows 7 Help Forums
    You have the solution for everything!Keep up the good work and Thanks
      My System SpecsSystem Spec


  6. Join Date : Oct 2013
    Posts : 16,449
    64-bit Windows 10 Pro build 14971
       2015-11-18 #6

    You're most welcome.
      My System SpecsSystem Spec


  7. Join Date : Aug 2015
    Posts : 19
    Windows 10 Pro 64bit
       2015-12-24 #7

    Bat File Operation Time Frame?


    Brink,

    I followed steps per instructions but file is still running after 15 minutes. Should it take this long? It appears to be reaching a certain point then restarting.

    My updates were working correctly until today.
      My System SpecsSystem Spec


  8. Join Date : Oct 2013
    Posts : 16,449
    64-bit Windows 10 Pro build 14971
       2015-12-24 #8

    Hello Archquark,

    No it should not take that long. It usually only takes a few seconds. It sounds like it's still trying to kill one of the services. Most likely the wuauserv service. The .bat has built in checks to make sure the necessary services are stopped before continuing. If they are not, it will keep trying.

    If you like, try manually stopping the service, and run the .bat again.

    If you are unable to stop the service, then restart the computer, and try running the .bat again.
      My System SpecsSystem Spec


  9. Join Date : Aug 2015
    Posts : 19
    Windows 10 Pro 64bit
       2015-12-26 #9

    Unable to stop Windows Update Service


    Brink,

    I went to services and found that Windows Update was shown as stopping and startup type was selected manual. I rebooted my computer but on checking saw that status and startup type has not changed. Any other suggestions would be appreciated. Option to stop service is grayed out.

    Click image for larger version. 

Name:	Screenshot (2).png 
Views:	1210 
Size:	211.2 KB 
ID:	55409
      My System SpecsSystem Spec


 
Page 1 of 8 123 ... LastLast


Similar Threads
Tutorial Category
Windows 8.1 & windows 10 : fail to factory reset and stuck in restart
Hi , I'm using windows 8.1 on ASUS N series laptop 64 bit, my windows got problem and after i updated to windows 10 and try to factory reset it, it got to 99% and say that the window has a problem, it cannot reset my windows and stuck in restart...
Installation and Setup
Reset after update?
I assume there was an update to Win 10 last night. Woke up this morning to find all my tweaking to the OS over the last several weeks was erased! Back to new born state. All my programs are still here but every single setting that I have checked...
General Support
Will Windows 10 Reset delete Windows 10 update?
I have tried everything and finally I decided to to completely reset my Windows and reinstall win 10. It gave me the option of deleting the hard drive. Securley. I did. But if Windows 10 is on there how is it going to install? Plus my PC Ethernet is...
Installation and Setup
Solved Win 10 Update Stuck in Reset Loop
My installation is stuck in a reset loop. The Win 10 Ready to Install came up, so I clicked Start and it rebooted, back to the login screen, and then Windows Update came up saying it needed to Restart Now. After a couple of minutes the Win 10...
Installation and Setup
reset windows update bat file
Hi, I had found this on a different site and saved it as "fix update.bat" and I run it when I have problems. It seems to help without breaking anything so I thought I'd post it. I'm not entirely sure what it does though @echo off net stop...
Windows Updates and Activation
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 13:24.
Find Us
Twitter Facebook Google+



Windows 10 Forums