WSUS command line tools

1. wsusutil.exe (on the server side)

WSUSutil.exe is a tool that you can use to manage your WSUS server from the command line.

Options are:
    export
    import
    reset
    deleteunneededrevisions
    migratesus
    movecontent
    listinactiveapprovals
    removeinactiveapprovals

Explanations:
Managing WSUS from the Command Line, Microsoft (english)
https://www.wsus.de/wsusutil/ (german)
WSUS Handbuch, Microsoft (german)

2. usoclient, (on the client side), not documentet by Microsoft, this is a replacement for 'wuauclt'.

First, USO stands for Update Session Orchestrator and it's the mechanism which replaced
the Windows Update Agent. As a part of the Windows Update service,
usoclient.exe
main role is basically a command to run tasks to either
scan for updates
, install or resume updates.

Options are:
    StartScan
    StartDownload
    ScanInstallWait
    StartInstall
    ResumeUpdate
    RefreshSettings
    RestartDevice
    StartInteractiveScan

Explanations:
Microsoft forum (english)
Borncity (german)
Automatic Updates Clienthttp://usoclient.com/ (english)

Manage WSUS Updates with powershell 1:

################
# Windows Update
################
# This only gets the signatures, not the 'Security Intelligence Update'
# to do this you need the NuGet Package Provider:
# run powershell with admin rights
   [Net.ServicePointManager]::SecurityProtocol=[Net.SecurityProtocolType]::Tls12
   Set-ExecutionPolicy bypass -scope process -force
   install-packageprovider -name NuGet -force
   Set-ExecutionPolicy remotesigned -force
   install-module PSWindowsUpdate

# in the list of the commands you will see the commandlets of the repository:
  get-command -module *update*

# to see the list of available updates, type
  get-windowsupdatelog

# install the 'Security Intelligence Update':
  get-windowsupdate -install -kbarticle "KB2267602"

Manage WSUS Updates with powershell 2:
  Stop-Service -Name wuauserv
  Remove-Item HKLM: \Software\Policies\Microsoft\Windows\WindowsUpdate -Recurse
  Start-Service -name wuauserv

Manage WSUS Updates with powershell 3:
  Set-ExecutionPolicy –ExecutionPolicy RemoteSigned -force
  Reset-WUComponents –verbose
  Get-WUList

Manage WSUS Updates with commandline 1:
  start cmd as admin
  dism.exe /Online /Cleanup-image /Restorehealth
  sfc /scannow

Manage WSUS Updates with commandline 2:
  net stop bits
  net stop wuauserv
  net stop appidsvc
  net stop cryptsvc
  Del "%ALLUSERSPROFILE%\Application Data\Microsoft\Network\Downloader\*.*"
  rmdir %systemroot%\SoftwareDistribution /S /Q
  rmdir %systemroot%\system32\catroot2 /S /Q
  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
  netsh winsock reset
  # netsh winsock reset proxy
  net start bits
  net start wuauserv
  net start appidsvc
  net start cryptsvc
 
Manage WSUS Updates with commandline 3:
  get ResetWUEng.cmd from
  https://github.com/ManuelGil/Script-Reset-Windows-Update-Tool
  start cmd as admin an run