A few days ago I noticed that my hosts file was not blocking sites as intended any more. Like any tech savvy user, I googled this problem and tried out various proposed solutions. Unfortunately as of this writing all the proposed solutions that I have tested so far have failed to work. I:
a. changed formatting in my hosts file
b. deleted hosts file when a. failed and got a completely clean new one
c. tried ipconfig/flushdns
d. uninstalled spybot, as per some suggestions
None of these solutions, even getting a new clean hosts file, have worked out. I have zero clue as to why this problem is not going away. Any help is appreciated.
-
anotherusername Notebook Consultant
-
...swinging for the fences
open regedit and navigate to
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\Tcpip\Parameters
is the databasepath key pointing to your host file? -
anotherusername Notebook Consultant
It said systemroot\system32.... and I changed it to C:\Windows\System32\... and no change. I then restarted and did another ipconfig/flushdns and still the host file continues to not work.
-
No, no, what is the whole datapath? you don't need to change that.
It SHOULD be
%SystemRoot%\System32\drivers\etc
don't change it to
c:\windows\System32\drivers\etc -
...also, in your previous folling around with your host file, you didn't accidently add an extension, did you (ie, making it hosts.txt)
-
(make sure that you are showing extensions under CONTROL PANEL > FOLDER OPTIONS > VIEW)
-
anotherusername Notebook Consultant
Ok, the datapath was exactly what you described. I reverted it back to its original form. And hosts file is not in .txt form. It just says "FILE" in the type section.
-
found another person with same issue and this fixed it for him, and others
Windows 7 Hosts File Ignored -
anotherusername Notebook Consultant
That is one of the first sites that pops up when you google "windows 7 hosts file not working". I tried out the solution from the main post there and all the small tweaks suggested in the comments section. The problem still persists.
-
attach your hosts file...
-
anotherusername Notebook Consultant
Here you go:
hosts -
Big hosts file.....
OK, the bad news, I guess, is that it works fine on my computer. That begs the question--how are you testing it? Are ads coming through you are trying to block? Are you able to ping the urls in the host file and get a response (note, you WILL get a response, it will just be from 127.0.0.1, instead of the actual ip address). -
anotherusername Notebook Consultant
I am testing hosts file by adding sites like google, cnn, facebook etc. and seeing if they get blocked. I am not sure what you mean by getting a response but I am unable to block them, blocked as in I should not be able to visit and use a site that is placed in my hosts file.
-
ok...I don't want to sound insulting, but how are you adding them?
In the hosts you attached, none of those were in there. Did you try to test one of the sites already in there? Any chance you just are not adding them correctly? -
open a command prompt with administrative privilidges
type the following
ping track.acclaimnetwork.com
what are the results? -
anotherusername Notebook Consultant
-
that is the correct response for a working HOSTS file
the 127.0.0.1 is a loopback address
If you ping track.acclaimnetwork.com without that entry in the host file, you're response would be
Reply from 67.23.26.37: bytes=32........
Your host file is "telling" your computer that track.acclaimnetwork.com is at 127.0.0.1, so we can see your HOSTS file is working, because the response is from your own computer (the loopback address).
You must be entering the information wrong.
Did you, for example, type in
Code:127.0.0.1 www.google.com
-
anotherusername Notebook Consultant
Ok, so I copy and pasted the information from the code window and it worked. I was unable to access google. I am not sure why it is working, but it is working now. I know for certain that when I was inserting 127.0.0.1 and copying and pasting the name of sites from address bar into hosts file I was still able to access them. Don't know why it is working now but I am glad that it is.
Thanks for all your assistance gerry. I appreciate it. -
Glad it is working....
you didn't include the http:// did you?
Windows 7 hosts file not working
Discussion in 'Windows OS and Software' started by anotherusername, Oct 20, 2012.