Why is my hosts file not working?

Posted by elliot100 on Server Fault See other posts from Server Fault or by elliot100
Published on 2010-05-05T16:36:50Z Indexed on 2010/05/05 16:38 UTC
Read the original article Hit count: 389

Filed under:
|
|

I've been using the hosts file to for local website development, and it's recently stopped working. No entries other than localhost resolve.

I've simplified to test, so it now contains only

127.0.0.1  localhost
::1        localhost
127.0.0.1  test.dev

localhost responds to ping, test.dev does not.

  • The file is called hosts with no extension
  • It has no trailing spaces
  • It's saved in C:\WINDOWS\System32\drivers\etc which matches the value of HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters\DataBasePath
  • Oddly, despite UAC being on, I can edit, delete and save the file without admin permissions
  • No proxy is being used, PC is not connected to network for testing
  • Stopping the DNS Client service seemed to resolve the issue for a few minutes, test.dev briefly resolved but doesn't any more.
  • Only firewall is Windows'
  • Machine has been restarted.

Is there anything else I should try?

© Server Fault or respective owner

Related posts about windows-vista

Related posts about hosts-file