How to Recover Windows System Files (SFC and DISM)
The Windows-integrated utility for checking system files (System File Checker tool or SFC) can scan system files for possible damage or other changes. If a file was modified, the utility will replace it with the proper version. Read this article to learn how to use SFC.
- When you need these two commands
- Run the SFC command to restore system files
- Use the DISM command to fix problems with SFC
- Restore or reset your operating system
If the SFC command doesn’t work, you can restore it from the system image using the DISM command (which is the abbreviation for Deployment Image Servicing and Management) in Windows 10 and 8. In Windows 7 and earlier versions of this operating system, Microsoft suggested using its System Update Readiness Tool.
When you need these two commands
Run the first command if you want to fix Windows errors. If Windows shows you a blue screen, applications crash or some Windows functions don’t work, use the SFC command to eliminate these issues. Even if it doesn’t restore any files, running this command will confirm that there are no damaged files in the operating system, so you can continue troubleshooting with other methods.
Obviously, DISM is not a command you would run just for fun. However, if the SFC command can’t fix a problem or restore a damaged system file, the DISM command (or the System Update Readiness Tool) can eliminate Windows system issues which enables SFC to run in the normal mode.
Run the SFC command to restore system files
This command should be launched from the Command Prompt started as Administrator. To open it in Windows 10 or 8.1, right-click on the Start button and select Command Prompt (Administrator). In all versions of Windows, you can also start this application from the search field next to the Start button: just type Command prompt in the search field and when a suitable result is displayed, right-click on it to select Run as administrator.
To start a system scan, type the following command in the window that appears, and press Enter:
Don’t close the Command Prompt window until the command is completed. It can take some time. If everything is fine, you will see this message: Windows Resource Protection did not find any integrity violations.
On the contrary, if you see the message Windows Resource Protection found corrupt files but was unable to fix some of them, try to restart the computer into the safe mode. To access the Advanced Boot Options menu in Windows 10, 8.1 or 8, hold down the Shift button and click Restart. In Windows 7 and earlier version of Windows, restart the computer, press and hold the F8 button until this menu shows up on the screen. Run the command sfc /scannow in the Safe Mode.
Use the DISM command to fix problems with SFC
In Windows 10, 8.1, and 8 the Deployment Image Servicing and Management tool can eliminate the errors that prevent normal operation of the SFC command.
In order to run this command, open the Command Prompt as administrator. Type the command and press Enter. DISM will check Windows components for errors and fix them automatically, if necessary.
DISM /Online /Cleanup-Image /RestoreHealth
Don’t close the Command Prompt window until the command is completed. This will take a few minutes. If the progress bar seems to stop at around 20%, don’t worry - it’s normal.
If the DISM command didn’t change anything, restart the computer. Now you can run the SFC command again and it will be able to replace any damaged files with good files.
Windows 7 and earlier versions of this operating system do not use the DISM command. Instead, you can launch the “System Update Readiness Tool” (make sure to download it from the Microsoft website before you start) and scan the system to find and fix errors and issues.
Restore or reset your operating system
If you tried all the steps above but your operating system is still in trouble, you can take more aggressive action. By running System Restore (?) you will restore operating system files to an earlier state, and this could fix errors and issues - provided your Windows wasn’t damaged before the last restore point was created.
Also, don’t forget about other options, such as resetting or reinstalling the operating system. In Windows 10, 8.1, and 8 you can go for Reset this PC to roll back to default settings.
While you are doing it, be attentive to choose the right option, as there are two ways to go:
- without removing files – i.e. without losing photos, music, videos and other user files;
- with all data removed – i.e. bringing the system back to its state after installation.
If you choose the second option, you can’t possibly restore your data with integrated Windows tools. If this option was chosen accidentally, there is no way to avoid using third-party file recovery tools.
The commands we explored in today’s article have other functions as well. For example, SFC can check only one of the Windows files for damage and restore it. With the DISM command, you can check the operating system for damage but without restoring anything.
SFC and DISM are very convenient commands that Microsoft developed to take care of its operating system, and it is good to have them when you need to save the operating system along with a large volume of important files.