FolderRisk: Caution
SoftwareDistribution C:\Windows\SoftwareDistribution
C:\Windows\SoftwareDistribution: Windows Update working folder (Download, DataStore). Emptied to repair a stuck update.
What it’s for
SoftwareDistribution is the Windows Update working folder: updates are downloaded here before they are installed, and the update history is kept here. The local database sits in DataStore\DataStore.edb. The folder is also part of the official steps for resetting Windows Update components.
What it contains
Download: temporary files of downloaded updates.DataStore: the Windows Update history database (DataStore.edb).ReportingEvents.log: the update event log.- A size that grows with downloads that are not purged.
Risks and best practices
- Only empty this folder when an update is stuck or downloads are corrupted. In that case, stop the
wuauservandbitsservices first, then emptyDownloadonly. - Microsoft describes a quick reset (stop
wuauserv, delete the folder, restart the service) and a manual procedure that renamesDataStore,Downloadandcatroot2to.bak. Keep the second for when the other steps have failed. Downloadis fetched again as needed. DeletingDataStore, on the other hand, resets the history shown in Settings.- Restart the services once you are done.
Useful commands
# As administratorStop-Service wuauserv, bits -ForceRemove-Item "$env:windir\SoftwareDistribution\Download\*" -Recurse -Force -WhatIf # remove -WhatIf to runStart-Service bits, wuauserv
# Generate a readable WindowsUpdate.log on the Desktop (merges the Windows Update .etl traces)Get-WindowsUpdateLog