|
|
HOSTS file does nothing?
microsoft.public.windowsxp.network_web
|
|

08-08-2008, 07:13 PM
|
|
|
|
HOSTS file does nothing?
Hi all,
I edited my hosts file recently to block out a couple of ad-server domains
and noticed it didn't do anything. Curious to test whether my hosts file
worked at all, I directed www.google.com to 127.0.0.1 and ran IE. It
promptly loaded www.google.com without any bother at all.
I rebooted and still had the same issue. It seems the HOSTS file is being
totally ignored. I've Googled for information on it but as far as I can
tell, Windows XP still makes use of this file?
I'm on XP Pro 64bit if that makes any difference?
TIA,
Alex
|
|

08-08-2008, 07:29 PM
|
|
|
|
Re: HOSTS file does nothing?
1. Do you have extension on the hosts file, for example hosts.txt?
2. if ping Google.com, do you receive 127.0.0.1?
--
Bob Lin, MS-MVP, MCSE & CNE
Networking, Internet, Routing, VPN Troubleshooting on
http://www.ChicagoTech.net
How to Setup Windows, Network, VPN & Remote Access on
http://www.HowToNetworking.com
"Alex Clark" <quanta@noemail.noemail> wrote in message
news:ORf6TrY%23IHA.4472@TK2MSFTNGP05.phx.gbl...
> Hi all,
>
> I edited my hosts file recently to block out a couple of ad-server domains
> and noticed it didn't do anything. Curious to test whether my hosts file
> worked at all, I directed www.google.com to 127.0.0.1 and ran IE. It
> promptly loaded www.google.com without any bother at all.
>
> I rebooted and still had the same issue. It seems the HOSTS file is being
> totally ignored. I've Googled for information on it but as far as I can
> tell, Windows XP still makes use of this file?
>
> I'm on XP Pro 64bit if that makes any difference?
>
> TIA,
> Alex
>
|
|

08-08-2008, 07:33 PM
|
|
|
|
Re: HOSTS file does nothing?
"Alex Clark" wrote:
> I edited my hosts file recently to block out a couple of ad-server domains
> and noticed it didn't do anything. Curious to test whether my hosts file
> worked at all, I directed www.google.com to 127.0.0.1 and ran IE. It
> promptly loaded www.google.com without any bother at all.
The hosts file in is "\WINDOWS\system32\drivers\etc" and has no extension.
Is it the file you've edited?
|
|

08-08-2008, 07:38 PM
|
|
|
|
Re: HOSTS file does nothing?
On Fri, 8 Aug 2008 15:33:22 -0400, "Bruno" <bgarbay@yahoo.com> wrote:
> "Alex Clark" wrote:
> > I edited my hosts file recently to block out a couple of ad-server domains
> > and noticed it didn't do anything. Curious to test whether my hosts file
> > worked at all, I directed www.google.com to 127.0.0.1 and ran IE. It
> > promptly loaded www.google.com without any bother at all.
>
> The hosts file in is "\WINDOWS\system32\drivers\etc" and has no extension.
> Is it the file you've edited?
And, Alex, exactly how did you edit it? Please copy and paste the line
here.
--
Ken Blake, Microsoft MVP - Windows Desktop Experience
Please Reply to the Newsgroup
|
|

08-08-2008, 07:49 PM
|
|
|
|
Re: HOSTS file does nothing?
"Alex Clark" <quanta@noemail.noemail> wrote in
news:ORf6TrY#IHA.4472@TK2MSFTNGP05.phx.gbl:
> Hi all,
>
> I edited my hosts file recently to block out a couple of ad-server
> domains and noticed it didn't do anything. Curious to test
> whether my hosts file worked at all, I directed www.google.com to
> 127.0.0.1 and ran IE. It promptly loaded www.google.com without
> any bother at all.
>
> I rebooted and still had the same issue. It seems the HOSTS file
> is being totally ignored. I've Googled for information on it but
> as far as I can tell, Windows XP still makes use of this file?
>
> I'm on XP Pro 64bit if that makes any difference?
>
> TIA,
> Alex
It is doubtful that the Hosts file is being ignored.
To test, try creating a new Hosts entry "abc" and assign it the
numeric IP address of, say, yahoo.com. Then try pinging "abc"...
A couple of things could cause the behavior you describe.
First: Are you accessing the internet through a proxy server? If so,
the proxy server will do the lookups for you.
Second: Browsers are sometimes too smart for their own good. It may
have tried "www.google.com", as specified, and it might have failed
because of your Hosts entry. It then might have automatically tried
"google.com" (which is _not_ the same as far as a Host file is
concerned) which probably did work.
HTH,
John
|
|

08-08-2008, 08:08 PM
|
|
|
|
Re: HOSTS file does nothing?
> 1. Do you have extension on the hosts file, for example hosts.txt?
Nope, it's just HOSTS and it's in my c:\windows\system32\drivers\etc folder
> 2. if ping Google.com, do you receive 127.0.0.1?
Yes! Which tends to imply that IE is doing its own lookup and ignoring the
HOSTS file...?
"Robert L. (MS-MVP)" <findemail@chicagotech.net> wrote in message
news:eMi5RzY%23IHA.3344@TK2MSFTNGP04.phx.gbl...
>
> --
> Bob Lin, MS-MVP, MCSE & CNE
> Networking, Internet, Routing, VPN Troubleshooting on
> http://www.ChicagoTech.net
> How to Setup Windows, Network, VPN & Remote Access on
> http://www.HowToNetworking.com
> "Alex Clark" <quanta@noemail.noemail> wrote in message
> news:ORf6TrY%23IHA.4472@TK2MSFTNGP05.phx.gbl...
>> Hi all,
>>
>> I edited my hosts file recently to block out a couple of ad-server
>> domains and noticed it didn't do anything. Curious to test whether my
>> hosts file worked at all, I directed www.google.com to 127.0.0.1 and ran
>> IE. It promptly loaded www.google.com without any bother at all.
>>
>> I rebooted and still had the same issue. It seems the HOSTS file is
>> being totally ignored. I've Googled for information on it but as far as
>> I can tell, Windows XP still makes use of this file?
>>
>> I'm on XP Pro 64bit if that makes any difference?
>>
>> TIA,
>> Alex
>>
>
|
|

08-08-2008, 08:16 PM
|
|
|
|
Re: HOSTS file does nothing?
Here are a couple of lines I've added:
127.0.0.1 google.com
127.0.0.1 www.google.com
Pinging either of the above resolves to 127.0.0.1. Surfing via IE takes me
to the Google homepage.
> First: Are you accessing the internet through a proxy server? If so,
> the proxy server will do the lookups for you.
I think you've just hit upon the problem - I believe my ISP has some sort of
transparent proxy. So they must be doing the lookup work then, rendering my
HOSTS file irrelevant ya reckon? That's a pain, because I could do with
filtering out a few domains.
AHA! Altering the IE connection settings to add a proxy exception for
addresses beginning with *.google.com seems to prevent it loading though!
At least that explains it, but I don't fancy having to add a long list of
blacklisted sites to that tiny little textbox in the IE settings. Sounds
like it may be the only solution though :-(
Thanks for all your help, and that goes to everyone on this thread.
Alex Clark
"John Wunderlich" <jwunderlich@lycos.com> wrote in message
news:Xns9AF4828B28wunderpsdrscray@138.126.254.210. ..
> "Alex Clark" <quanta@noemail.noemail> wrote in
> news:ORf6TrY#IHA.4472@TK2MSFTNGP05.phx.gbl:
>
>> Hi all,
>>
>> I edited my hosts file recently to block out a couple of ad-server
>> domains and noticed it didn't do anything. Curious to test
>> whether my hosts file worked at all, I directed www.google.com to
>> 127.0.0.1 and ran IE. It promptly loaded www.google.com without
>> any bother at all.
>>
>> I rebooted and still had the same issue. It seems the HOSTS file
>> is being totally ignored. I've Googled for information on it but
>> as far as I can tell, Windows XP still makes use of this file?
>>
>> I'm on XP Pro 64bit if that makes any difference?
>>
>> TIA,
>> Alex
>
> It is doubtful that the Hosts file is being ignored.
> To test, try creating a new Hosts entry "abc" and assign it the
> numeric IP address of, say, yahoo.com. Then try pinging "abc"...
>
> A couple of things could cause the behavior you describe.
>
>
> Second: Browsers are sometimes too smart for their own good. It may
> have tried "www.google.com", as specified, and it might have failed
> because of your Hosts entry. It then might have automatically tried
> "google.com" (which is _not_ the same as far as a Host file is
> concerned) which probably did work.
>
> HTH,
> John
|
|

08-08-2008, 09:37 PM
|
|
|
|
Re: HOSTS file does nothing?
Hi
Maybe this can Help, http://www.ezlan.net/host.html
Jack (MS, MVP-Networking)
"Alex Clark" <quanta@noemail.noemail> wrote in message
news:ORf6TrY%23IHA.4472@TK2MSFTNGP05.phx.gbl...
> Hi all,
>
> I edited my hosts file recently to block out a couple of ad-server domains
> and noticed it didn't do anything. Curious to test whether my hosts file
> worked at all, I directed www.google.com to 127.0.0.1 and ran IE. It
> promptly loaded www.google.com without any bother at all.
>
> I rebooted and still had the same issue. It seems the HOSTS file is being
> totally ignored. I've Googled for information on it but as far as I can
> tell, Windows XP still makes use of this file?
>
> I'm on XP Pro 64bit if that makes any difference?
>
> TIA,
> Alex
>
|
|

08-08-2008, 11:53 PM
|
|
|
|
Re: HOSTS file does nothing?
"Alex Clark" <quanta@noemail.noemail> wrote in
news:#s0M4OZ#IHA.1224@TK2MSFTNGP02.phx.gbl:
> Here are a couple of lines I've added:
>
> 127.0.0.1 google.com
> 127.0.0.1 www.google.com
>
> Pinging either of the above resolves to 127.0.0.1. Surfing via IE
> takes me to the Google homepage.
>
>> First: Are you accessing the internet through a proxy server?
>> If so, the proxy server will do the lookups for you.
>
> I think you've just hit upon the problem - I believe my ISP has
> some sort of transparent proxy. So they must be doing the lookup
> work then, rendering my HOSTS file irrelevant ya reckon? That's a
> pain, because I could do with filtering out a few domains.
>
> AHA! Altering the IE connection settings to add a proxy exception
> for addresses beginning with *.google.com seems to prevent it
> loading though!
>
> At least that explains it, but I don't fancy having to add a long
> list of blacklisted sites to that tiny little textbox in the IE
> settings. Sounds like it may be the only solution though :-(
>
> Thanks for all your help, and that goes to everyone on this
> thread. Alex Clark
>
>
>> HTH,
>> John
Thanks for the feedback.
-- John
|
|
| Thread Tools |
|
|
| Display Modes |
Linear Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT. The time now is 02:09 PM.
|
|