ComputersOS

The HOSTS file in the C: \ Windows \ System32 \ drivers \ etc folder is damaged: what should I do?

Today, quite often, users of social networks like "VKontakte" or "Odnoklassniki" meet with the problem of entering the site. The system monitors this by means of the HOSTS file, which is located in the tree C: \ Windows \ System32 \ drivers \ etc. Unfortunately, it is this service that is most often affected by viruses. Let's try to figure out how to fix the situation.

Which files are in the C: \ Windows \ System32 \ drivers \ etc directory, and what are they responsible for?

First, let's look at the files in this folder. In addition to the desired file, there should be only four more objects. If there is anything else, you can safely say that it is a virus or something like that.

As for the functions of files, for example, the C: \ Windows \ System32 \ drivers \ etc \ services object and other files, including HOSTS, protocol, lmhosts and networks, are responsible for some user access to certain resources on the Web.

The HOSTS file under consideration determines the correspondence of the domain name database to IP addresses. In addition, its use implies accelerating user access to the most frequently visited pages on the Internet bypassing DNS servers, as well as blocking some unwanted resources or banner links. By default, in addition to the descriptive text part, it contains a single record of interest to us at the end of the text, namely: 127.0.0.1 localhost. All! There should not be any additional entries in it.

Checking the IP address of sites

If you are talking about the example of matching a domain name to a real IP address of a resource, you can test it in an absolutely elementary way, using the standard input of the ping command on the command line, after which the URL of the checked resource is indicated via a space.

To obtain the IP of any resource, you must use the following combination: ping www. (Site name). (Domain ownership). For example, for a Facebook network, this would look like ping www.facebook.com. After executing the command on the screen, the required address and statistics of the so-called pinging will be displayed.

What should I do if the file is infected with a virus?

Unfortunately, it is the C: \ Windows \ System32 \ drivers \ etc \ HOSTS file that infects the virus most often. After that, when a user logs on to the same social network, either his redirection to the site-clone occurs, or in general a message with the demand for payment of the entrance is issued. Immediately make a reservation: not a single "sotsialka" for using the services of the resource does not take money. Hence the conclusion: it is a virus (sometimes an artificial blockage, which is extremely rare).

If this is the case, you should first check the computer system with an antivirus scanner. In some cases, do not even use the antivirus installed in the system, since it has already missed the threat, and there is no guarantee that it will detect it and delete it as a result of scanning on demand.

It is better to run some portable utilities like Dr. Web (best Cure IT!) Or KVRT, which does not even require installation. But even such powerful products do not always help, and the blocking of access to resources written in the file C: \ Windows \ System32 \ drivers \ etc \ HOSTS remains and continues to work. Let's see how you can get rid of it.

Manually correcting the text of a file

First we go to the C: \ Windows \ System32 \ drivers \ etc directory, then select our file and right click call the menu with the command "Open with ..." (initially the system file itself does not open with a double click, since it does not have an extension) . Now from the list of available programs choose the standard "Notepad" and look at the contents of the text.

As a rule, in an infected file there may be records like 127.0.0.1, after which the resource addresses of the same "social networks" (for example, 127.0.0.1 odnoklassniki.ru) are indicated. This is the first sign that they are produced due to malicious code being triggered. It turns out that the control elements of the system, referring to the HOSTS file, constantly block the site when trying to access it.

The simplest method of correction is to delete all the contents when you later insert the original text (it can be taken from another computer or found on the Internet). After that, just save the changes (Ctrl + S) and reboot the computer terminal. You can, of course, try to replace the desired file with the original one, but it is unlikely that the system will allow it even if there are administrative rights. In addition, this option works in about 20-30% of cases.

Problems with hidden HOSTS file and lmhosts.sam object

The problem can often be more serious. The fact is that sometimes when you enter the C: \ Windows \ System32 \ drivers \ etc directory, the HOSTS file you need is visually missing.

First, in the "Explorer" you should use the service menu, and then select the folder settings, where the option of displaying hidden objects (files and folders) is activated. In addition, you need to shoot "birds" from the lines of hiding protected system files and extensions for registered types. Now our file is visible.

However, real problems begin here. The point is that when you try to edit or save the system, the system displays a message stating that the file C: \ Windows \ System32 \ drivers \ etc \ HOSTS is not writable. What to do in this case?

We apply the cardinal measures - delete the HOSTS file, preferably from the Recycle Bin. Quickly remove it bypassing the Trash can be combined with Shift + Del. Then right click on the free space of the window and select the command to create a new text file and call it hosts or HOSTS without an extension, whatever you like, it does not matter. We agree with the warning system regarding the change of the extension and we proceed to editing. As already understood, the actions are the same as the previous version - just insert the original content and save the newly created document. After that, delete the lmhosts.sam file (it affects the operability of the desired host file), and then again reboot the system.

This option will restore access to your favorite sites that were previously blocked. By the way, this method works almost always.

Instead of an afterword

As can be seen from the above, to fix the problem of blocking Internet resources can be quite simple, without even having for this some special knowledge and skills. However, before you start editing the HOSTS system object, you should make sure that the standard anti-virus scan did not do anything. Some users try to use utilities like Microsoft Fix It. Note that if there is a virus in the system, the files will be infected again, and the fixes will be made only for a while.

Similar articles

 

 

 

 

Trending Now

 

 

 

 

Newest

Copyright © 2018 en.delachieve.com. Theme powered by WordPress.