Many people know that you can check the integrity of Windows system files using the sfc / scannow command (however, not everyone knows this), but few know how else to use this command to check system files.
In this instruction, I will show how to test for those who are not familiar with this team at all, and after that I will talk about the various nuances of its use, which, I think, will be interesting. See also more detailed instructions for the latest OS version: checking and restoring the integrity of Windows 10 system files (plus video instructions).
How to check system files
In the basic version, if you suspect that the necessary Windows 8.1 (8) or 7 files were damaged or lost, you can use the tool specifically provided for these cases by the operating system itself.
So, to check the system files, follow these steps:
- Run the command line as administrator. To do this, in Windows 7, find this item in the Start menu, right-click on it and select the corresponding menu item. If you have Windows 8.1, then press Win + X and run “Command Prompt (Administrator)” from the menu that appears.
- At the command prompt, type sfc / scannow and press Enter. This command will check the integrity of all Windows system files and try to fix them if any errors were found.
However, depending on the situation, it may turn out that the use of checking system files in this form is not fully suitable for this particular case, and therefore I will talk about additional features of the sfc utility command.
Additional SFC verification options
A complete list of parameters with which to run the SFC utility is as follows:
SFC [/ SCANNOW] [/ VERIFYONLY] [/ SCANFILE = file path] [/ VERIFYFILE = file path] [/ OFFWINDIR = windows folder] [/ OFFBOOTDIR = remote download folder]
What does this give us? I suggest looking at the points:
- You can start only checking system files without fixing them (below is information on why this might come in handy) using
- It is possible to check and fix only one system file by executing the command
sfc /scanfile=путь_к_файлу (or verifyfile, if you do not need to fix it).
- To check system files not in the current Windows (but, for example, on another hard drive), you can use
sfc /scannow /offwindir=путь_к_папке_windows
I think these features can be useful in a variety of situations when you need to check system files on a remote system, or for some other unforeseen tasks.
Possible problems when checking
When using the system file check utility, you may encounter some problems and errors. In addition, it is better if you know some of the features of this tool, which are described below.
- If, when starting sfc / scannow, you see a message stating that Windows Resource Protection cannot start the recovery service, check that the “Windows Module Installer” service is enabled and the startup type is set to “Manual”.
- If you have modified files in the system, for example, you replaced the icons in Windows Explorer or something else, then performing a check with automatic correction will return the files to their original form, i.e. if you changed files on purpose, it will have to be repeated.
It may turn out that sfc / scannow will not be able to fix errors in the system files, in this case you can enter at the command line
findstr /c:"[SR]" %windir%\Logs\CBS\CBS.log >"%userprofile%\Desktop\sfc.txt"
This command will create a sfc.txt text file on the desktop with a list of files that could not be fixed - if necessary, you can copy the necessary files from another computer with the same version of Windows or from the OS distribution.