System File Checker in Windows 10 command
To launch the sfc command perform the following steps:
- Click Start.
- In the search bar, type CMD .
- Right-click CMD.exe and select Run as Administrator.
- On the User Account Control (UAC) prompt, click Yes.
- In the command prompt window, type SFC /scannow and press Enter .
- System file checker utility checks the integrity of Windows system files and repairs them if required.
Scans and verifies the integrity of all protected system files and replaces incorrect versions with correct versions. If this command discovers that a protected file has been overwritten, it retrieves the correct version of the file from the systemroot\system32\dllcache folder, and then replaces the incorrect file.
You must be logged on as a member of the Administrators group to run this command.
sfc [/scannow] [/verifyonly] [/scanfile=<file>] [/verifyfile=<file>] [/offwindir=<offline windows directory> /offbootdir=<offline boot directory>]
|/scannow||Scans the integrity of all protected system files and repairs files with problems when possible.|
|/verifyonly||Scans the integrity of all protected system files, without performing repairs.|
||Scans the integrity of the specified file (full path and filename) and attempts to repair any problems if they’re detected.|
||Verifies the integrity of the specified file (full path and filename), without performing repairs.|
||Specifies the location of the offline windows directory, for offline repair.|
||Specifies the location of the offline boot directory for offline repair.|
|/?||Displays help at the command prompt.|
To verify the kernel32.dll file, type:
To set up the offline repair of the kernel32.dll file with an offline boot directory set to *D:* and an offline windows directory set to D:\windows, type:
sfc /scanfile=D:\windows\system32\kernel32.dll /offbootdir=D:\ /offwindir=d:\windows