Skip to content

Instantly share code, notes, and snippets.

@mikebranstein
Created September 1, 2016 20:26

Revisions

  1. mikebranstein created this gist Sep 1, 2016.
    14 changes: 14 additions & 0 deletions disable-windows-update.ps1
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,14 @@
    # set the Windows Update service to "disabled"
    sc.exe config wuauserv start=disabled

    # display the status of the service
    sc.exe query wuauserv

    # stop the service, in case it is running
    sc.exe stop wuauserv

    # display the status again, because we're paranoid
    sc.exe query wuauserv

    # double check it's REALLY disabled - Start value should be 0x4
    REG.exe QUERY HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\wuauserv /v Start