0x80070002

Fix 0x80070002: Missing File or System Restore Fail

This error usually means Windows Update or System Restore can't find a needed file. The fix is often clearing the SoftwareDistribution folder or checking the date.

Cause 1: Corrupted Windows Update cache (most common)

I know this error is infuriating — you're trying to install an update or run System Restore, and boom: 0x80070002 with a message about a missing file. In my help desk days, nine times out of ten, the culprit was a corrupted update cache. Windows stores downloaded updates in the C:\Windows\SoftwareDistribution folder. If a download gets interrupted or a file gets mangled, the update can't find what it needs.

Here's the fix that works for most people. Stop the Windows Update service, clear the cache, then restart it. Open Command Prompt as Administrator — right-click Start, choose "Command Prompt (Admin)" or "Windows Terminal (Admin)" on Windows 11. Then run these commands one at a time:

net stop wuauserv
net stop cryptSvc
net stop bits
net stop msiserver
ren C:\Windows\SoftwareDistribution SoftwareDistribution.old
ren C:\Windows\System32\catroot2 catroot2.old
net start wuauserv
net start cryptSvc
net start bits
net start msiserver

This renames the old cache folders so Windows creates fresh ones next time it checks for updates. Don't delete them — renaming lets you revert if something goes weird. I've done this on hundreds of machines — Windows 7 through 11 — and it almost always clears the error. Run Windows Update again after this. If it still fails, move to Cause 2.

Cause 2: Wrong date or time on your PC

This one tripped me up the first time too. Windows Update and System Restore both check timestamps on files. If your system clock is off — like way off, not just five minutes — the error 0x80070002 shows up. I've seen this happen after a dead CMOS battery on desktops, or when dual-booting with Linux resets the hardware clock.

Right-click the clock in the taskbar and pick "Adjust date/time." Turn on "Set time automatically" and "Set time zone automatically." If they're already on, toggle them off and back on to force a sync. Then hit "Sync now" under "Additional settings." For older Windows 10 builds, you might need to pick a time server manually — use time.windows.com or pool.ntp.org. If the date is still wrong after that, your CMOS battery is probably dead. That's a hardware fix — swap the CR2032 battery on the motherboard. I've seen a bad battery cause this error for months before anyone figured it out.

Cause 3: Corrupted system files (SFC and DISM)

Sometimes the error isn't about the update itself — it's that the Windows component needed to process the update is broken. System File Checker (SFC) and Deployment Imaging Service and Management (DISM) are your friends here. Run these in order, from an elevated Command Prompt:

DISM /Online /Cleanup-Image /RestoreHealth
sfc /scannow

DISM fixes the image that SFC uses. Let DISM finish — it can take 15-20 minutes on older hardware. Then SFC scans and replaces any corrupt files. I've seen this fix persistent 0x80070002 errors that survived cache clears and clock resets. If SFC finds files it can't repair, you might need a manual replacement, but that's rare — 90% of the time DISM + SFC does the job.

Quick-reference summary

CauseFixDifficulty
Corrupted update cacheStop services, rename SoftwareDistribution & catroot2, restart servicesIntermediate
Wrong date/timeSync clock, toggle auto settings, replace CMOS battery if neededBeginner
Corrupted system filesRun DISM /RestoreHealth then SFC /scannowIntermediate

Skip the rabbit hole of registry edits or reinstalling Windows for this error — those are overkill. Start with the cache clear, check your clock, then run DISM + SFC. In my experience, one of those three always does it. If you're still stuck after all three, you might be dealing with a failing hard drive or bad RAM — run chkdsk /f and a memory diagnostic to rule that out. But for 95% of people, this article covers it.

Related Errors in Windows Errors
0X000000A4 Fix ERROR_MAX_THRDS_REACHED (0x000000A4) on Windows 10/11 0X000021B1 Fix ERROR_DS_AUDIT_FAILURE (0X000021B1) on Domain Controllers 0XC00D2740 NS_E_DRM_INVALID_APPDATA (0XC00D2740) – DRM data is corrupt 0XC00D0FA9 NS_E_USER_STOP (0XC00D0FA9) – Stop Fixes for Windows Media

Was this solution helpful?

EP
Erropedia Team
Tech Support Editors
The Erropedia editorial team researches and documents real-world tech errors from across Windows, Linux, macOS, networking, databases, cloud platforms, and more. Every solution is reviewed for accuracy and updated as software and systems evolve.