Windows.  Viruses.  Notebooks.  Internet.  office.  Utilities.  Drivers

You have probably heard of such a useful utility as sfc. As part of Windows, it allows you to check system files for inconsistencies with the original version, which is very useful when the original system files have been replaced by a crooked installer, an evil virus, or a careless user. Undoubtedly, Windows Vista and Windows 7 brought system security and protection of their files to new level and reduced the likelihood of system files being spoofed. Reduced, but not excluded, and it is very difficult to protect yourself from the inquisitive mind and curiosity of the user.

Therefore, if, as a result of certain actions, your system refuses to boot, and you suspect (or even firmly believe) that the matter is in replacing an important system file with a corrupted instance, you can execute checking the integrity of system files using WinRE ( Windows Recovery environment), right on the "fallen" system.

Running the sfc.exe utility from the Windows 7 Recovery Environment

1. Paste installation disk Windows 7 to DVD drive and boot from DVD. Wait for this window to appear:

Set the keyboard layout to "US" and click "Next".

2. In the next window, click System Restore.

3. Now select the damaged instance of Windows 7 from the list and click Next. I have one.

4. Run command line

To check and restore one specific file, type
sfc /scanfile=X:\windows\explorer.exe /offbootdir=X:\ /offwindir=X:\windows

Replace X: with the letter of the partition where your system is located.

To check all files operating system, run the command
sfc /scannow /offbootdir=X:\ /offwindir=X:\windows

You are not being deceived, the check can really take some time, in my case it lasted about 7 minutes. Upon completion, the utility will display the path to the log of its work, and tell you what it did with system files.

In this issue, I will show you how to check the integrity of the system Windows files 10, and if they are corrupted, I will show you how to restore these files using the SFC and DISM commands.

No user is immune from errors in the Windows 10 operating system. They may arise due to its deliberate or accidental interference with the operation of the OS, as well as through the fault of third-party applications. If the operating system starts complaining about missing files, registry errors, or the inability to read items from Windows folders, you will need to check the integrity of its components.

The Windows 10 operating system provides 2 methods for analyzing the integrity of files - through tools sfc.exe And DISM.exe. The commands do not replace each other, but complement each other by checking the various libraries of the system for file integrity. That is why it is recommended to perform not one of them, but both. The tools will allow you to check the integrity of Windows 10 files and replace damaged or modified ones with original items.

Please note that if you or the Administrator of the computer specifically made changes to the system files of the operating system earlier, they will be canceled. Windows tools will replace the changed items with the original ones, even if the problem with the computer or application is not caused by their actions.

Check the integrity of files in Windows 10 using SFC

It is recommended to start checking the integrity of operating system files with the command SFC. It allows you to find errors in key files and fix them.

You can check using SFC both in the familiar Windows 10 interface through the command line, and through the recovery environment, then we will analyze both of these methods.

Method-1: Through the command line in the Windows interface

It is better to start checking with SFC through the standard Windows interface using the command line. Most of the time this is enough.

To check the integrity of files, do the following:

  • Run command prompt as administrator (btw). I use keyboard shortcut Win+X and in the menu that opens on the left, select the item "Command Prompt (Admin)"
  • We register the command sfc /scannow and press Enter;
  • After that, the process of scanning the system and replacing damaged (modified) elements will begin.

If there are no problems with the Windows system files, after checking we will see a message that "Windows Resource Protection found no integrity violation".

In such a situation, you can go

However, in some situations, files that are responsible for displaying GUI Windows, and their system will not be able to fix, because they are active. In such cases, it is necessary to check the SFC through a recovery environment that does not require loading a graphical interface and is able to work with these files, as well as modify them if necessary.

note, if you suspect that the system failure is related to a specific file, you can not perform a full SFC check. It is enough to enter the command sfc /scanfile=”address to file”, and it will be replaced instantly with the original version if it has been previously modified or malfunctions.

Method-2: Through the recovery environment

To check the integrity of files using the SFC command through the recovery environment, you will need to perform the following steps:

  1. Click on the button in the lower left corner "Start" and go to "Options";
  2. Next, select "Update and Security", on the left side of the screen, click the tab "Recovery" and in paragraph « Special Options download" click "Restart now". As a result of these actions, the computer will go into reboot;
  3. After that, you will need to start the system with advance. Will appear first language selection screen, and then suggestion to install the system. At this stage, you need to click on the inscription in the lower left corner "System Restore";
  4. The recovery environment will load, where you need to run the command line. To do this, click "Troubleshooting", then point "Extra options" and select an option "Command line";
  5. Next, the command line will start, in which you must sequentially write the commands below, and after each of them press Enter:

After executing the second command, a list of available volumes will be displayed. Here you need to pay attention to the disk that is reserved by the system and to system partition with the operating system. Next, they will need to be manipulated.

Continue typing commands:

sfc /scannow /offbootdir=C: /offwindir=E:Windows

The last command requires you to specify the drives that were marked above. That is, in the above command example drive C is the bootloader partition, and disk E- the place where the Windows 10 operating system is installed.

Attention: It is highly likely that your drive letters will differ from those given in the example, so the command will vary.

  1. After entering the last of the four commands, scanning the integrity of the operating system files will begin.

The advantage of working through the recovery environment is the ability of the SFC tool to replace the files that are needed to load the Windows GUI.

Check in this case will last a little longer than when working through the command line in the operating system interface. At the same time, the command line in the recovery environment will not graphically inform the user about the speed of the process. You can determine that the computer is working properly and the file integrity check has not hung by the flashing underline icon.

At the end of the check, the user will see information that integrity violations were not detected or were successfully fixed. After that, you can proceed to the second verification method - using the DISM tool.

Check File Integrity in Windows 10 Using DISM

As noted above, after checking with SFC, it is recommended to start analyzing the system with the DISM tool. It examines other directories during the check (and once again "walks" through the files that were checked by SFC).

Checking with the DISM tool is somewhat different from analyzing the system using SFC. The user has the option to select one of three commands to check the system. Each of them has a different level of impact.

When this command is executed, the system checks the entries made by the diagnostic utilities for the detection of modified or problematic files in the system. The command is executed quickly, but there is no validation, and all data is based on previously recorded information.

dism /Online /Cleanup-Image /ScanHealth

This command is aimed at analyzing all system components to identify errors and damaged elements in them. In this case, only a check is performed, and the user is notified of the presence or absence of problematic files. Such a check can take from several minutes to several hours, depending on the speed of the hard drive, its workload and the degree of interference with the files of the operating system.

dism /Online /Cleanup-Image /RestoreHealth

This command, unlike the previous one, not only checks the files, but also immediately replaces them with complete ones. It will also take from several minutes to several hours to complete.

Important: Please note that the last two commands that run the Windows 10 File Integrity Check may “freeze” in progress at a certain percentage (most often around 20). In no case should you reboot the system at this moment, since this situation is typical, and the interest will continue to “drip” after a while.

VIDEO: How to check FILE INTEGRITY in Windows 10?

Well, that's all for today! Please write in the comments if you have ever checked the integrity of your system files? Or you prefer not to bother and just reinstall it.

And if you liked this video, give it a thumbs up and don't forget to subscribe to my youtube channel and alerts by clicking on the bell next to the subscribe button!

System File Checker ( System File Checker), built into Windows, can check system files for damage and any other changes. If the file has been modified, the utility will automatically replace it with the correct version.

When to use these commands

These commands are useful in diagnosing a malfunctioning operating room. Windows systems. If the system produces a blue screen, applications crash, or some system functions do not work, the SFC command can help. Even if nothing is fixed after executing the SFC command, this will make it possible to make sure that the system files are not damaged and you can continue diagnosing in other ways.

The DISM command is not required under normal circumstances. But if the SFC command fails or fails to replace the corrupted files with normal ones, DISM or the System Update Readiness Tool can fix the operating system itself and allow the SFC command to run normally.

Fixing system files with the SFC command

The SFC command must be run as an administrator. To do this, in Windows 10 or 8.1, click right click click on the Start icon and select the Command Prompt (Admin) option. In addition, in all Windows versions you can search in the start menu/on home screen according to the words "command line", click on the desired link with the right mouse button and select "Run as administrator" (Run as Administrator).

For a full system scan, enter the following command in a command prompt window and press :

Do not close the window until the command completes. The process can be quite lengthy. If everything is in order, following the results of the check, the message “Windows Resource Protection did not find any integrity violations” will appear.

If the message "Windows Resource Protection found corrupt files but was unable to fix some of them" appears, first try to boot the system into safe mode. In Windows 10, 8.1 or 8, to do this, hold down the key while selecting the "Restart" option in the shutdown menu to get to the screen for choosing advanced boot options. On Windows 7 and above early versions restart your computer and hold down the key during startup. After booting into safe mode, run the sfc /scannow command again.

Troubleshooting SFC with DISM

In Windows 10, 8.1, and 8, you can use the Deployment Image & Servicing Management (DSIM) tool to fix component store corruption that is preventing SFC from working properly.

To run this tool, open a command prompt window as an administrator, type the following command, and then click . DISM will check the storage Windows components for damage and will automatically fix any problems found.

DISM /Online /Cleanup-Image /RestoreHealth

Do not close the command prompt window until the process is complete. The check may take up to 10 minutes. If the progress bar stays at 20% for a long time, don't worry, it's normal.

If any changes are made as a result of running the DISM command, restart your computer. After that, run the SFC command again and it will be able to replace the corrupted files with the correct ones.

Windows 7 and earlier do not have the DISM command. Instead, you can download the System Update Readiness Tool from the official Microsoft website, which allows you to check the system for problems and try to fix them.

System restore or reset

If problems persist and cannot be fixed with these tools, more drastic measures can be taken. The System Restore tool allows you to return Windows to an earlier state, which will solve the problem if the operating system was still working in that state.

You can also reset Windows to factory state or reinstall. In Windows 10, 8.1, and 8, you can use the Restore Computer () function, which allows you to return Windows to its original state. After that, you will have to reinstall all programs, but user files will not be affected. In Windows 7 and earlier, you should use a recovery partition created by your computer manufacturer, or simply reinstall Windows from scratch.

If other errors occur when you run the above commands, try searching the Internet for them. Often, the output of a command contains information about log files (logs), which can provide more detailed information about certain problems. And in the end, it’s not at all necessary to spend time diagnosing complex problems when you can simply restore factory condition Or reinstall Windows.

The commands described above have other possibilities. For example, using SFC, you can check and fix individual system files. A with using DISM can be done quick check unpatched systems, or point the utility to a WIM or ESD file containing Windows system files.

materials

Often, users are forced to believe that the system files of the operating system (OS) are damaged, the reason is characteristic failures when performing elementary operations and slow work computer. It happens that loading an external IT product leads to a destructive change in the OS configuration. In these cases, checking the integrity of system files in Windows 10 helps.

Usually, the OS provides two software product SFC.exe and DISM.exe, and in addition the Repair-WindowsImage command to Windows PowerShell. The former check the integrity of the components of the system and automatically restore their identified defects. The second one does this by using DISM.

Experts are sure that it is more expedient to use them one by one, since the lists of scanned files for these software tools differ from each other.

In continuation, consider a few instructions for using the presented software. The described actions are safe, but it must be remembered that restoring system files is complex, and even affects those changes that are made by the user himself. In particular, the installation of external resources and other OS conversions will be cancelled.

Examination of the integrity of the system and the correction of its elements using SFC

The sfc /scannow OS integrity scan command is popular among experienced users. It automatically investigates and eliminates defects in OS components.

The functioning of SFC is carried out on behalf of the administrator, through the command line, which opens by right-clicking on the Start menu. Next, enter sfc /scannow and press "Enter".

These actions begin the OS check, as a result of which the detected damage is corrected. If there are no errors, the user sees the message "Windows Resource Protection found no integrity violations." Another aspect of this study is irreparable damage. Part of the continuation of this article will be devoted to them.

The sfc /scanfile="path_to_file" command allows you to check for errors in a specific system component.

The disadvantage of the software tool is that it does not eliminate the defects of the OS elements used during the scan. The problem is solved by running SFC through the command line in the OS recovery environment. This method is quite effective, and involves performing a few simple operations.

Investigating Integrity Using SFC in an OS Recovery Environment

It does not take much time, and does not require special skills. Starting in the OS recovery environment is performed in several ways:

  1. You need to enter the "Settings" and alternately select "Update and security", "Recovery", "Special boot options" and "Restart now". A simpler method: in the lower right part of the OS login interface, the “on” tab is pressed, after which, while holding “Shift”, you must click “Reboot”.
  2. Another option is to boot from a pre-prepared OS recovery disk.
  3. Another alternative - electronic media with OS distribution. In the installer, after selecting the language, "System Restore" is selected at the bottom left.


When finished, you need to enter the "Troubleshooting", select "Advanced Options" and click "Command Prompt" (using the first of the previously presented methods involves entering the system administrator password). The following is applied in sequence:

  • diskpart
  • list volume


After running the specified commands, the user sees a list of volumes. It is recommended to remember their designations corresponding to the System Reserved disk and the OS partition, as sometimes they differ from those in Explorer.

sfc /scannow /offbootdir=F:\ /offwindir=C:\Windows (where F is the previously specified System Reserved drive and C:\Windows is the path to the OS folder).


The described actions initiate a deep examination of the integrity of the system, during which the SFC command fixes all damaged components, without exception. The study can take a long time. The underline indicator flickers to indicate that the system is still running. When finished, the command prompt closes and the OS reboots in standard mode.

Scanning and repairing the system using DISM.exe

It happens that the SFC team cannot cope with some defects in system components. The IT product DISM.exe allows you to complete the restoration that you have begun. It scans and maintains the system, fixing even the most problematic components.

DISM.exe is used even when SFC does not detect OS integrity defects, and there is reason to suspect that they exist.

First of all, right-clicking on the Start menu as an administrator launches a command prompt. Then other commands are run:

  • dism /Online /Cleanup-Image /CheckHealth. It is used to generate information about the state of the OS, the presence of damage to its components. Does not initiate research, scans for earlier values ​​of fixed parameters.


  • dism /Online /Cleanup-Image /ScanHealth. Investigates and verifies the integrity of the system component repository. It takes a lot of time, barely breaking the 20% mark.


  • dism /Online /Cleanup-Image /RestoreHealth. Explores and automatically restores the OS. Works slowly, intermittently at times.


In circumstances where system item storage cannot be restored, use install.wim (esd) with the Windows 10 ISO as the source of the fixables. There is another option for this:

dism /Online /Cleanup-Image /RestoreHealth /Source:wim:wim_file_path:1 /limitaccess

IN individual cases".wim is replaced by .esd."

During the use of these commands, all performed operations are logged, which is contained in Windows\Logs\CBS\CBS.log and Windows\Logs\DISM\dism.log. The DISM tool runs in the OS recovery environment in the same way as it does when running SFC.

This software tool also implemented in Windows PowerShell as an administrator using the Repair-WindowsImage command set. For example:

  • Repair-WindowsImage -Online -ScanHealth. Looks for defects in system elements,
  • Repair-WindowsImage -Online -RestoreHealth. Investigates and troubleshoots.

Apparently, restoring the integrity of the OS is a completely feasible task, the solution of which allows you to get rid of various problems with the system. In rare cases, when the described tools do not help, you should use other algorithms that are in open access. In particular, you should try to roll back the system to the previous point Windows recovery 10.

Some users are experiencing that SFC detects defects in system elements immediately after updating with a new OS build. Under these conditions, error correction is possible only with a new "clean" installation of the system image. Sometimes damage is detected in individual versions software for video cards. In this case, the opencl.dll file is erroneous. It may not be worth taking any action at all in these circumstances.

Conclusion

The described methods for studying the integrity of the OS are simple and effective. The stages of their implementation are clear to most of the audience of users, including those who do not have special programming skills. However, to consolidate the material, there will be useful videos which are publicly available in world wide web Internet.

Not all errors are expressed in windows that appear on the desktop and the inability to perform any action. Much more often, they imperceptibly accumulate on your computer and gradually slow down its work. Periodically check the device for possible errors, and not only the system, but also HDD, and registry. All the methods described below include the automatic correction of the faults found.

How to check the system for integrity and errors

As a result of incorrect shutdown of the computer, exposure to viruses and other problematic situations, system files may be damaged or changed. The consequences of this, as a rule, are expressed in problems at startup. individual programs or turning on the computer, but sometimes they may not be visible to the user. Scanning the system for integrity is the first thing we recommend doing when you encounter problems with Windows 10.

Through the sfc command

This is the main way to check the integrity of the operating system. It is intended for cases with problems with the performance of the computer. Through the sfc command, only a superficial analysis is carried out, with the help of which it will not be possible to find and fix all possible errors. However, this method is quite fast and is ideal for preventive computer scans. A deeper analysis is possible through the DISM utility, which is described below.

The sfc command cannot fix errors in files that are currently in use by the system. If you receive a notification about such failures, be sure to run the DISM utility.

Through the DISM utility

The DISM utility performs a full system scan for errors and integrity violations. The analysis launched by it lasts quite a long time, but it allows you to identify and correct all violations in the system. Internet is required for verification.

Before starting the utility, disable the antivirus and that's it. running programs and also try not to use the computer during the analysis.

Open command prompt as administrator and type dism /Online /Cleanup-Image /RestoreHealth.


For a complete analysis of the integrity of the system, enter the command dism /Online /Cleanup-Image /RestoreHealth at the command line

There are a few more commands of this utility that you may find useful:

  • dism /Online /Cleanup-Image /CheckHealth for information about the status and presence of damage to Windows components;
  • dism /Online /Cleanup-Image /ScanHealth to check the integrity and corruption of the component store.

How to check hard drive for errors

All data written to the computer is divided into small fragments, which are placed on sectors hard drive. During the operation of the computer, these sectors can be damaged. Bad sectors are hard disk "errors". When the hard drive tries to read information from a bad sector, the reading process "stops". The result of this is unnecessarily long turning on the computer and launching some programs.

You cannot fix bad sectors, but you can prevent the hard drive from working with them. The process of finding and eliminating these sectors is called defragmentation. Even if no errors are found, as a result of defragmentation, the space on the hard disk will become more ordered, which will also speed up the process of reading information.

Through the "Explorer"

This is the main way to check the hard drive. Windows 10 should do it automatically, without the knowledge of the user, in order to keep the hard drive in order. Defragmentation will take you about an hour, so it's best to leave it overnight.


Through the "Control Panel" (storage diagnostics)

Many mistakenly believe that through the storage diagnostic utility, you can analyze the hard drive. Actually it is not. The storage diagnostic utility is indeed present on the hard drive, but it starts automatically, and you won't be able to do an analysis through it. This way you can only get the results last check hard drive status.

If you just want to analyze, use the previous method, but instead of "Optimize" click "Analyze".


Through the command line

This method eliminates the restoration of order on the hard disk, which is performed during normal defragmentation. This makes the process much faster. Correcting errors in this way is recommended if you need to quickly recover information from bad sectors.


To check without using the Internet, use the chkdsk C: /F /R /offlinescanandfix command.

Via PowerShell

Windows PowerShell is a powerful new shell for the command line. She does the same as her predecessor, but has much more powers. PowerShell allows you to quickly and easily perform those actions that are difficult or impossible for a conventional command line. In our case, this will help to avoid the need to restart the computer to check the sectors in use.


To check without using the Internet, use the Repair-Volume -DriveLetter C -OfflineScanAndFix command.

Video: how to check a hard drive for errors

How to check the registry for errors

The Windows Registry is a complex database of the operating system that stores all settings, changes, information about the computer and installed programs. In the event of a registry error, the consequences can be very different: from blue screen when turned on and the system is completely inoperable to an unremovable shortcut and other trifles.

The most annoying feature of registry errors is their layering. One minor error in the registry can lead to several others, which will ultimately lead to sad consequences. This is why regularly scanning your registry for errors and fixing them early is extremely important to keep your computer running at top speed.

Via built-in

Windows 10 has a built-in utility for checking the integrity of the registry, but it is rather weak and does not find most errors. It is best to use one of third party programs which are described below.

This method can only fix critical errors: many registry faults will remain untouched.

Open a command prompt as an administrator, type scanreg /fix and press Enter.


Enter the scanreg /fix command to check the registry through the built-in Windows utility 10

Via CCleaner

CCleaner is the most popular and reliable computer cleaning program. It is designed to clean debris from hard-to-reach places that the system itself cannot reach. However, CCleaner deserved its popularity precisely for its registry cleaning function, which allows you to quickly find and overwrite registry errors without affecting anything important.


Via Glary Utilities

Glary Utilities - very functional program, which will run in the tray and keep your computer clean and tidy. Cleaning the registry is just one of the available features to improve your computer. Glary Utilities may seem intrusive to many, but for inexperienced users, it will be a very useful assistant.


Via Wise Registry Cleaner

Wise Registry Cleaner- a program designed not so much to treat the registry, but to completely clean it from stale and unclaimed parameters. Cleaning the registry with Wise Registry Cleaner is quite serious and can affect important files that the program seems superfluous. The first time you run Wise Registry Cleaner, you will be prompted to do backup registry, which is better to agree. If important files are affected, you can always roll back.

Wise Registry Cleaner is available only on the English version of the official website: when you change the page language to Russian, you will be offered another Wise Care 365 program.


Even if you don't see any errors on your computer, it's best to scan it periodically. This will keep your system running smoothly and help resolve most issues before they become noticeable.

If you notice an error, select a piece of text and press Ctrl + Enter
SHARE: