How to Fix "Error 0x80070005: Access Denied" When Installing Windows Updates
Problem Explanation
You're trying to install important Windows updates, but the process grinds to a halt, displaying an error message: "There were problems installing some updates, but we let you know about it so you can try again. Error 0x80070005 – Access Denied." This message indicates that Windows Update components lack the necessary permissions to access, modify, or delete files or folders required for the update process. Essentially, the system is preventing the update mechanism from performing its intended actions. This can be frustrating as it blocks crucial security patches and feature enhancements, leaving your system vulnerable.
Why It Happens
The "Error 0x80070005: Access Denied" typically occurs when the Windows Update service or its associated components encounter permission issues on critical system files or folders. This can stem from several sources. Corrupted system files, incorrect security permissions on the SoftwareDistribution folder (where Windows stores downloaded update files), or issues with the Windows Update service itself are common culprits. In some cases, third-party security software might aggressively block access to certain system areas, mistaking legitimate update activities for malicious behavior. Malware infections can also alter system file permissions, leading to this error.
Step-by-Step Solution
## Step 1: Run the Windows Update Troubleshooter
The built-in Windows troubleshooter is designed to automatically detect and fix common Windows Update problems.
- Navigate to Settings > Update & Security > Troubleshoot.
- Click on Additional troubleshooters.
- Select Windows Update and then click Run the troubleshooter.
- Follow the on-screen prompts and allow the troubleshooter to make any necessary changes.
- Restart your computer after the troubleshooter has completed.
## Step 2: Check File and Folder Permissions for the SoftwareDistribution Folder
The SoftwareDistribution folder is where Windows stores update files. Incorrect permissions here can cause access denied errors.
- Open Command Prompt as an administrator. To do this, search for "cmd" in the Start menu, right-click on "Command Prompt," and select "Run as administrator."
- Stop the Windows Update service by typing the following command and pressing Enter:
net stop wuauserv - Stop the Cryptographic Services by typing the following command and pressing Enter:
net stop cryptSvc - Stop the Bits service by typing the following command and pressing Enter:
net stop bits - Stop the Software Protection service by typing the following command and pressing Enter:
net stop sppsvc - Rename the SoftwareDistribution folder. Navigate to
C:\Windows\SoftwareDistributionusing File Explorer. Rename the folder toSoftwareDistribution.old. - Rename the Catroot2 folder. Navigate to
C:\Windows\System32. Rename thecatroot2folder tocatroot2.old. - Restart the Windows Update service by typing the following command and pressing Enter:
net start wuauserv - Restart the Cryptographic Services by typing the following command and pressing Enter:
net start cryptSvc - Restart the Bits service by typing the following command and pressing Enter:
net start bits - Restart the Software Protection service by typing the following command and pressing Enter:
net start sppsvc - Close the Command Prompt and try running Windows Update again.
## Step 3: Reset the Windows Update Components Manually
If renaming the folders doesn't resolve the issue, manually resetting the Windows Update components can help. This is a more thorough process than simply renaming.
- Open Command Prompt as an administrator.
- Execute the following commands one by one, pressing Enter after each:
net stop wuauservnet stop cryptSvcnet stop bitsnet stop msiserver - Delete the contents of the SoftwareDistribution folder. Navigate to
C:\Windows\SoftwareDistributionin File Explorer. Delete all files and folders inside this folder. Do not delete the folder itself. - Delete the contents of the Catroot2 folder. Navigate to
C:\Windows\System32. Delete all files and folders inside thecatroot2folder. Do not delete the folder itself. - Re-register the DLL files associated with Windows Update. In the administrator Command Prompt, type and press Enter for each command:
regsvr32 mshtml.dllregsvr32 shdocvw.dllregsvr32 browseui.dllregsvr32 jscript.dllregsvr32 vbscript.dllregsvr32 scrrun.dllregsvr32 msxml.dllregsvr32 msxml3.dllregsvr32 msxml6.dll - Restart the services. In the administrator Command Prompt, type and press Enter for each command:
net start wuauservnet start cryptSvcnet start bitsnet start msiserver - Close the Command Prompt and restart your computer. Then, try running Windows Update again.
## Step 4: Temporarily Disable Antivirus Software
Sometimes, aggressive antivirus programs can interfere with the Windows Update process by blocking access to certain files or services.
- Locate your antivirus software's icon in the system tray (usually at the bottom-right of your screen).
- Right-click on the icon and look for an option to "Disable," "Turn off," or "Exit." Select the option that will temporarily disable real-time protection.
- Try running Windows Update.
- Crucially, remember to re-enable your antivirus software immediately after the update process is complete. Failure to do so leaves your system vulnerable to threats.
## Step 5: Run System File Checker (SFC) and DISM
Corrupted system files can also lead to access denied errors during updates. SFC and DISM can help repair these.
- Open Command Prompt as an administrator.
- Run the System File Checker. Type the following command and press Enter:
sfc /scannow - Wait for the scan to complete. If SFC finds and repairs corrupted files, restart your computer and try updating again.
- If SFC cannot repair the files or the problem persists, run the Deployment Image Servicing and Management (DISM) tool. Type the following commands one by one, pressing Enter after each:
DISM /Online /Cleanup-Image /ScanHealthDISM /Online /Cleanup-Image /CheckHealthDISM /Online /Cleanup-Image /RestoreHealth - Once DISM has completed, run
sfc /scannowagain. - Restart your computer and attempt to install Windows Updates.
## Step 6: Check Permissions for the Windows Update Service
Ensure the Windows Update service has the correct permissions to access necessary files and folders.
- Search for "Services" in the Start menu and open the Services application.
- Locate the Windows Update service in the list.
- Right-click on the Windows Update service and select Properties.
- Go to the Log On tab. Ensure that "Local System account" is selected. If it's not, select it and click Apply, then OK.
- While still in the Properties window, go to the Recovery tab. Set the "First failure," "Second failure," and "Subsequent failures" to Restart the Service. Click Apply, then OK.
- Right-click on the Windows Update service again and select Restart.
- Try running Windows Update.
Common Mistakes
A common mistake when encountering this error is to repeatedly run the Windows Update troubleshooter or attempt to download and install updates manually without addressing the underlying permission issues. Simply restarting the computer or the Windows Update service without performing the necessary file and folder permission checks or component resets is often insufficient. Another pitfall is disabling antivirus software and forgetting to re-enable it, leaving the system exposed. Over-aggressive manual modifications to registry keys related to Windows Update without proper backups or understanding can also exacerbate the problem.
Prevention Tips
To prevent "Error 0x80070005: Access Denied" from recurring, maintain a proactive approach to system health. Regularly run Windows Update and install all available updates promptly. Ensure your antivirus software is up-to-date and configured correctly, but avoid settings that are overly restrictive. Perform regular system file checks using sfc /scannow and DISM to catch and repair minor corruptions before they escalate. Keep your operating system and drivers updated from official sources. Consider creating a system restore point before making significant system changes or installing new software that might alter system permissions.