How to Fix: 'sfc /scannow' Fails, Won't Complete
Infopackets Reader Terry C. writes:
" Dear Dennis,
I am trying to run the command 'sfc /scannow' (system file checker) through the Windows command prompt to repair corrupt Windows files, but every time I try and run 'sfc /scannow', it stops at 42% and gives the error message 'Windows Resource Protection could not perform the requested operation.' Therefore, the 'sfc /scannow' does not complete and I can't repair my corrupt Windows files. How can I fix this so I can finish running the scan and fix my files? "
Update 20200116: I'm getting a lot of emails from folks asking for help on this. If you want this problem fixed ASAP, send me an email and don't forget to leave your phone number. I will call you back as soon as possible.
My response:
I had the "Windows Resource Protection could not perform the requested operation" error recently, and the best way to resolve the issue is to reboot into safe mode and try and run 'sfc /scannow' through an administrative command prompt. That is easier said than done, however, as there are a number of steps you need to take before that can happen. Plus, there will likely be some issues along the way, including the possibility that the system file checker will also fail in Safe Mode, resulting in the "Windows Resource Protection found corrupt files but was unable to fix some of them" error, which is also a major pain to resolve.
As such, I've written this article to explain how to properly run the 'sfc /scannow' command in Safe Mode, as well as how to resolve the "Windows Resource Protection could not perform the requested operation" error, including the "Windows Resource Protection found corrupt files but was unable to fix some of them" error.
Please note that the instructions on this page apply to Windows XP, Vista, 7, 8 and Windows 10.
In short, here are the summary of steps I've outlined in this document:
- Scan the Hard Drive for Errors
- Enable the Hidden Administrator Account
- Set the Computer to Reboot in Safe Mode
- Login as the Administrator User
- Open an Administrative Command Prompt
- Ensure that PendingDeletes and PendingRenames Folders Exist
- Run the 'sfc /scannow' command in Safe Mode
- Parse the CBS.log File if System File Checker Fails
- Replace Corrupt System Files: for Windows XP, Vista, and 7 users
- Replace Corrupt System Files: for Windows 8 and 10 Users
With that said, let's get started.
Scan the Hard Drive for Errors
The first thing to do is to tell Windows you want to perform a file system check on the hard drive to ensure there are no errors. If there are errors on the drive, 'sfc /scannow' may fail.
To scan the drive for errors, do the following:
- Open an administrative command prompt. In Windows XP, click Start -> Run, and type in "cmd.exe" and press Enter. In Windows Vista, 7, 8, and 10: Click Start and type in "cmd" (no quotes). Wait for Command Prompt or CMD.EXE to appear in the list of options and right click it, then select "Run as Administrator".
- A black command prompt window will appear on the screen. Highlight the following text with your mouse: "chkdsk /x /f /r" (do not include the quotes), then right click over the highlighted text and select Copy. Next, go to the command prompt and right click in the middle of the window and select Paste from the dialogue menu. The command you copied should have output to the command prompt. If it did not, repeat this step until it does. After the command is output, press Enter on your keyboard to execute it. When prompted, press "Y" to have chkdsk scan your hard drive for errors on the next reboot.
Don't close the command prompt yet as there are more commands to enter.
Enable the Hidden Administrator Account
Next we'll enable the hidden administrator account so that you can perform the 'sfc /scannow' command in a clean environment.
To do so:
- Highlight the following text with your mouse: "net user administrator /active:yes" (do not include the quotes), then right click over the highlighted text and select Copy. Next, go to the command prompt and right click in the middle of the window and select Paste from the dialogue menu. The command you copied should have output to the command prompt. If it did not, repeat this step until it does. After the command is output, press Enter on your keyboard to execute it.
- Please note that you will most likely want to disable the administrator account after you have finished making changes listed in this document, otherwise anyone will be able to login to your computer as the administrator user without using a password and make changes to the system without any authorization. You can disable the administrator account using the exact steps you just took above, except you would replace "net user administrator /active:yes" with "net user administrator /active:no".
Proceed to the next step.
Set the Computer to Reboot in Safe Mode
Now you will need to reboot the computer in Safe Mode. One of the easiest ways to do that is to set the Safe Mode option using the msconfig utility.
To do so:
- In Windows XP, click Start -> Run, and type in "msconfig" (no quotes) and press Enter. In Windows Vista, 7, 8, and 10, click Start and type in "msconfig" (no quotes) and press Enter.
- The msconfig window will appear; click the Boot menu tab near the top. Under the "Boot options" heading, tick the "Safe Mode" box and then click Apply, then OK. You will most likely have a window that pops up asking you to reboot. You can choose to reboot now, or do it manually from the start Menu.
- After the computer reboots it will perform a file system check on the C drive. If it finds any, the system may reboot again.
Note: you will need to undo the Safe Mode setting after you have finished making changes listed in this document, otherwise the system will continue to reboot in safe mode repeatedly. To undo the Safe Mode, simply remove the check mark that you ticked off in the steps above.
Proceed to the next step.
Login as the Administrator User
When chkdsk has finished scanning the drive, you will be taken to the login screen; choose to login as the Administrator user. After doing so, you may have to wait a few minutes for Windows to create the administrator desktop in order to complete the login, so please be patient. Also note that there is no password set for the hidden Administrator user; you only need to click the account to login with no password.
Open an Administrative Command Prompt
Once you've logged in as the Administrator user, the next step is to open an administrative command prompt.
To do so: In Windows XP, click Start -> Run, and type in "cmd.exe" and press Enter. In Windows Vista, 7, 8, and 10: Click Start and type in "cmd" (no quotes). Wait for Command Prompt or CMD.EXE to appear in the list of options and right click it, then select "Run as Administrator". A black command prompt window will appear on the screen.
Proceed to the next step.
Ensure that PendingDeletes and PendingRenames Folders Exist
Note: Windows XP users can skip the instructions below because it does not apply to them. Instead, skip ahead to the section that reads "Run the 'sfc /scannow' command in Safe Mode" immediately below.
According to the document, "Use the System File Checker tool to repair missing or corrupted system files" (Microsoft KB 929833), you will also need to ensure that two folders exist on your system before you can run the 'sfc /scannow' command again.
To ensure the folders exist, do the following:
- Highlight the following text with your mouse: "mkdir %WinDir%\WinSxS\Temp\PendingDeletes %WinDir%\WinSxS\Temp\PendingRenames" (do not include the quotes), then right click over the highlighted text and select Copy. Next, go to the command prompt and right click in the middle of the window and select Paste from the dialogue menu. The command you copied should have output to the command prompt. If it did not, repeat this step until it does. After the command is output, press Enter on your keyboard to execute it.
- If you receive an error that a folder already exists, ignore the error.
Run the 'sfc /scannow' command in Safe Mode
The next thing to do is to run the 'sfc /scannow' in the command prompt.
To do so:
Highlight the following text with your mouse: "sfc /scannow" (do not include the quotes), and copy it to your clipboard as you did previously. Go to the command prompt and paste the command using the right click. The command you copied should have output to the command prompt. If it did not, repeat this step until it does. After the command is output, press Enter on your keyboard to execute it.
System File Checker (sfc) should now execute and scan the system until it reaches 100%. If it fails before 100% with either the error message that "Windows Resource Protection found corrupt files but was unable to fix some of them, proceed to the next step immediately below", or "Windows Resource Protection could not perform the requested operation", then you will need to proceed to the next section, "Parse the CBS.log File if System File Checker Fails," or perform a Windows Repair Install (described as the very last option further down).
If it does not fail, then you have achieved what you have set out to do, and you should pat yourself on the back. You will now need to disable Safe Mode using msconfig so you can reboot your system normally. In that case, launch msconfig as previously described and remove the checkmark next to the safe mode option. You will also most likely want to disable the administrator user; in that case, refer to the section on enabling the administrator user and disable the account.
Parse the CBS.log File if System File Checker Fails
If the 'sfc /scannow' command fails before it reaches 100% (with the error "Windows Resource Protection found corrupt files but was unable to fix some of them, proceed to the next step immediately below" most likely), then you will need to parse the CBS.log file (which is created by system file checker) in order to figure out which file is corrupt on the system.
To do so:
- Using the administrative command prompt window that is already open from the previous step above, highlight the following text with your mouse: "findstr /c:"[SR]" %windir%\logs\cbs\cbs.log >%userprofile%\Desktop\sfcdetails.txt" (do not include the quotes). Right click the highlighted text and select Copy, then go to the command prompt window, paste the command, and press Enter on the keyboard to execute it.
- Windows should have placed a file on your desktop called "sfcdetails.txt". It will contains parts of the CBS.log file that will specifically tell you which file on your system is corrupt and causing the 'sfc /scannow' command to fail. Double click on the sfcdetails.txt and scroll through the file and note any errors listed in the log.
Proceed to the next step.
Replace Corrupt System Files: for Windows XP, Vista, and 7 users
If you run Windows XP, Vista, and Windows 7, you can replace the corrupt file from your Windows DVD if you have one.
There are a few caveats with this approach, however:
- If there are many files to replace, it might be easier to insert the Windows DVD (if you have one) into the drive, reboot, and do a "repair" install (rather than a full reinstall). A repair install is similar to a full reinstall but you wouldn't lose your installed programs. You will however need to download a lot of updates after the repair.
- You can extract the corrupt files from the original DVD without doing a repair. This is the preferred method if you don't have a lot of files to replace, though you will have to locate the original path where the corrupt file is stored (according to the sfcdetails.txt log file), then go through the install.wim file the original Windows DVD and replace the damaged file(s). Providing instructions on how to do this is too lengthy for this document, so I've provided a link to a page that explains it.
- If you don't own a Windows DVD and only have a 'recovery partition' then you best bet is to either obtain the correct and non-corrupt file(s) from another source (such as another PC with the exact same operating system), or reinstall Windows using your recovery partition if you have one.
Optionally, you can do a repair install (described as the last step), which is most likely the easiest option.
Replace Corrupt System Files: for Windows 8 and 10 Users
If you own Windows 8 or 10 then you can run the 'DISM' file utility to replace the corrupt files using Microsoft's servers.
To do so:
- Open an administrative command prompt by clicking on Start, and then type in "cmd" (no quotes). Wait for Command Prompt or CMD.EXE to appear in the list of options and right click it, then select "Run as Administrator".
- A black command prompt window will appear on the screen. Highlight the following text with your mouse: "Dism /Online /Cleanup-Image /StartComponentCleanup" (do not include the quotes), then right click over the highlighted text and select Copy. Next, go to the command prompt and right click in the middle of the window and select Paste from the dialogue menu. The command you copied should have output to the command prompt. If it did not, repeat this step until it does. After the command is output, press Enter on your keyboard to execute it.
- Repeat the same steps as above, except enter the command "Dism /Online /Cleanup-Image /RestoreHealth" (do not include the quotes).
- Wait for DISM to complete its scan and hopefully it will report back it made some fixes. After that completes, try running 'sfc /scannow' again in the same command prompt and pray that it reaches 100%. If it does not, then you will have to use the same approach to repair corrupt files described above for Windows XP, Vista, and 7 users.
Optionally, you can do a repair install (described next), which is most likely the easiest option.
Update 20200116: I'm getting a lot of emails from folks asking for help on this. If you want this problem fixed ASAP, send me an email and don't forget to leave your phone number. I will call you back as soon as possible.
Additional 1-on-1 Help: From Dennis
If all of this is over your head, or you still can't get Windows Update to work properly, I can assist you using remote desktop support. Simply contact me and we'll set up a time to meet.
About the author: Dennis Faas is the owner and operator of Infopackets.com. With over 30 years of computing experience, Dennis' areas of expertise are a broad range and include PC hardware, Microsoft Windows, Linux, network administration, and virtualization. Dennis holds a Bachelors degree in Computer Science (1999) and has authored 6 books on the topics of MS Windows and PC Security. If you like the advice you received on this page, please up-vote / Like this page and share it with friends. For technical support inquiries, Dennis can be reached via Live chat online this site using the Zopim Chat service (currently located at the bottom left of the screen); optionally, you can contact Dennis through the website contact form.
Most popular articles
- Which Processor is Better: Intel or AMD? - Explained
- How to Prevent Ransomware in 2018 - 10 Steps
- 5 Best Anti Ransomware Software Free
- How to Fix: Computer / Network Infected with Ransomware (10 Steps)
- How to Fix: Your Computer is Infected, Call This Number (Scam)
- Scammed by Informatico Experts? Here's What to Do
- Scammed by Smart PC Experts? Here's What to Do
- Scammed by Right PC Experts? Here's What to Do
- Scammed by PC / Web Network Experts? Here's What to Do
- How to Fix: Windows Update Won't Update
- Explained: Do I need a VPN? Are VPNs Safe for Online Banking?
- Explained: VPN vs Proxy; What's the Difference?
- Explained: Difference Between VPN Server and VPN (Service)
- Forgot Password? How to: Reset Any Password: Windows Vista, 7, 8, 10
- How to: Use a Firewall to Block Full Screen Ads on Android
- Explained: Absolute Best way to Limit Data on Android
- Explained: Difference Between Dark Web, Deep Net, Darknet and More
- Explained: If I Reset Windows 10 will it Remove Malware?
My name is Dennis Faas and I am a senior systems administrator and IT technical analyst specializing in cyber crimes (sextortion / blackmail / tech support scams) with over 30 years experience; I also run this website! If you need technical assistance , I can help. Click here to email me now; optionally, you can review my resume here. You can also read how I can fix your computer over the Internet (also includes user reviews).
We are BBB Accredited
We are BBB accredited (A+ rating), celebrating 21 years of excellence! Click to view our rating on the BBB.
Comments
There was a recent problem with System File Checker
I would just like to make everyone aware of a recent problem that I encountered with System File Checker (SFC). For those that installed Windows update KB3022345, thereafter SFC reported irreparable corruption errors when, in reality, there were no errors. Only when I uninstalled that patch was SFC able to run through with no errors being found. My only point in telling you this is that it happened in the last month or so and was driving me crazy with trying to fix this "problem" when, come to find out, the cause was KB3022345. I hope you don't go through what I went through to "fix" this "problem".
If you're like me, you don't want to uninstall any patch provided by Microsoft, especially when you don't know what it does and the Microsoft description is so vague as to be useless. So, if you have Microsoft update KB3022345 installed and you now have SFC indicating there are problems, you can easily correct them without uninstalling KB3022345 by following the instructions here:
For Windows 7:
http://thetechcookbook.com/windows-7-update-kb3022345-causing-corrupt-files/
For Windows 8:
http://thetechcookbook.com/windows-8-update-kb3022345-causing-corrupt-files/
The problem is one of permission settings. No logic changes are made in the above website instructions. I had the problem in Windows 7 and the simple procedure at the above URL (for Windows 7) corrected it. SFC once again runs cleanly.
Commands inside your posts
Instead of putting commands in side quotes and then having to state, Do not include quotes, why don't you use italics, bold, or another font?
How to Fix: 'sfc /scannow' Fails
I go and download from Microsoft the System Update Readyness Tool.
I then run it. Every time I have solved my problem by doing this. No other steps are necessary.
I would like to know if any body else has used this solution.
System update readiness tool = Windows Update fix
The system update readiness tool is meant to fix a broken Windows Update. SFC is the "system file check" (SFC) utility which is meant to fix corrupt or broken operating system files - though it doesn't always work and neither does the system update readiness tool. If your SFC errors are related to a broken Windows Update, then I supposed it is possible that the system update readiness tool would resolve your problems. However, this will not apply to most cases where SFC is failing.
THANK YOU, THANK YOU, THANK YOU!
Holy crap! I spent all day trying to figure this out. I've been to more websites in a day than I've been to all year! No one had the answer...not even Microsoft! I owe you something for this...something perhaps... X-rated. J/K Seriously, I am soooooo appreciative that you took the time to post all if this...and in simple language, with easy-to-follow directions. This is literally the best "technical" post I've ever read. You should be giving a class in how to communicate these concepts to laypeople. Thanks again, and best wishes.
Just needed to create a new Windows 10 user account
Thanks for such wonderful instructions. I found many bits and pieces of your step-by-step instructions on other sites and had tried some, but this list was so thorough. Funny thing is that I found the solution with your help, but not because the instructions fixed the problem.
I was missing the Settings; browsers couldn't open pages; sometimes Windows 10 would go to a black screen showing only the mouse cursor; etc. As I went through your instructions, I got to the point where I had to create an Administrator account. I noticed in the Administrator account that I could do some of the things I couldn't do in my broken account. So after finishing everything in your instructions, I decided to create a new user account. That took care of the problem!
I had previously copied all files from my old user account to a thumb drive. Then I copied them to the new user account, and it works perfectly. Crazy! I wonder what would cause such problems that would affect an account, but that's what happened.
Anyway, thanks again!
Corrupt user account
What you probably had was a corrupt user account, though one that can't run an administrative command prompt is rare unless your access rights have been hosed. At any rate, that is partly why I put in instructions on how to login as Administrator.
100% complete, but still can't preform the opperation
So I was having issues on my Win10 desktop, and the blue screen error came up with critical process died, and running the sfc was said to fix it in a fix I read. After trying this, the operation couldn't be performed, so I found this link to try and figure out how to fix it. After doing all the steps above before parsing the CBS.log file, the verification phase completed, 100%. As soon as it finished, the error message Windows Resource Protection could not perform the requested operation, so I ran it once more just to be sure. The same thing happened again. After that I decided to continue to the next section, to see if I could do anything from where I was at.I read a line into it and realized that that section was if there were corrupted files it was unable to fix. Alas, that was not the error message that my computer was showing to me, so I feared if I did proceed, I would screw my desktop up even more. With my issues, should I continue and parse the CBS.log file, or should I hold off and try and find another fix? Thanks millions for putting this out, by the way, I feel like it's very helpful and easy to read for those that think they know about tech although they really don't(like myself).
Remote desktop support service
original path to file not on installation DVD
Hi Dennis,
this is a VERY helpful tutorial, thank you!
my cbs.log tells me ieframe.dll in \SystemRoot\WinSxS\amd64_microsoft-windows-ieframe_31bf3856ad364e35_11.2.9600.18499_none_47006eb7c327003f\ieframe.dll cannot be repaired
but my installation DVD only contains E:\sources\install.wim\4\Windows\winsxs\amd64_microsoft-windows-ieframe_31bf3856ad364e35_8.0.7600.16385_none_db51a57e3ed2086d\ieframe.dll
This is win 7 ultimate.
Thanks for any suggestions
How to Fix: 'sfc /scannow' Fails, Won't Complete
Hello Dennis. I have been working on this Toshiba Satellite laptop (L70D-A) for a friend. Have tried numerous things that haven't helped. SFC/scannow will run to 77% then stop with an error. I decided to try your fix (from title of my comment) I have been stuck at "Scanning and repairing drive (C:): 10%" for almost 1.5 hours.
While this was running I read some of the comments and was wondering if I can safely stop this scan and start with checking for the Windows update "KB3022345" that is known to cause problems on some computers...
I just powered off the
I just powered off the computer and rebooted. Did another sfc/scannow and it only got to 59% before stopping for errors. Other than the lack of WIFI this computer seems to run normal now. I had to delete original user acct and make a new one.
Now I'm in reboot loop.
Now I'm in reboot loop. Trying to start then I get a blue screen with something like this... https://i0.wp.com/www.angel.org/gadgetsense/wp-content/uploads/2012/03/vhdfail.jpg