Why can't my Browser resolve host, but ping and nslookup can?

14

3

I'm a bit stumped by this problem. My machine can ping google.com and www.google.com successfully. I get correct ips like 74.125..

When I try to go to google in Firefox or IE or Chrome, I get a typical dns error page. For some reason, Safari is still working.

My first guess was a caching issue, but after clearing all browser caches I still see the problem. Second guess was that malware reconfigured my proxy settings, but no luck there either. Everything is set to "No proxy". I downloaded wireshark and the browser is querying my dns server.

Other sites resolve fine in all browsers. Everything seems to be working as expected but... Basically, I have run out of ideas on this one.

In response to comments:

  • IP directly in browser works, obviously. This is a DNS issue, not a connection issue.
  • Clearing the DNS cache in windows did not fix the problem. Checking the chrome internals shows that www.google.com could not be resolved.
  • My hosts file is clean (no entries).
  • Rebooting does not fix the problem.

Gregm

Posted 2012-02-21T00:54:03.540

Reputation:

I had this problem and it turned out to be my hosts file. I have no idea why I had added an entry for this particular domain. I just wanted to say thanks for posting the question and prompting me to check my hosts file! – gazareth – 2015-06-09T12:44:16.880

a) This should be on SuperUser b) try using the IP directly in the browsers that aren't working - some firewalls can be configured to block specific programs - check yours. c) Chrome maintains its own DNS cache - about:dns also check about:net-internals#dns d) try flushing your DNS cache (ipconfig /flushdns) – cyberx86 – 2012-02-21T01:01:54.880

be aware that nslookup uses its own DNS Client. Have you checked your hosts file (the new favorite malware file-to-edit)? – Mathias R. Jessen – 2012-02-21T01:11:30.267

have you rebooted? Sometimes browsers try internet before wireless has come up all the way and then don't notice that internet has started to work again. Closing browser or rebooting usually fix this. – Robert – 2012-02-21T01:21:05.050

Answers

4

For others without a virus: Your browser contains a DNS cache of its own. Try resolving the URL in Firefox or Edge. If you get a different result in Chrome, clear Chrome's DNS cache. Start here:

chrome://net-internals/#dns.

You'll have to copy/paste the link text into Chrome's onmibox. For more help, follow instructions here.

Clearing Chrome's cache causes no adverse effect.

ndemarco

Posted 2012-02-21T00:54:03.540

Reputation: 350

1You can also take the more scientific approach of examining Chrome's cache for the URL not working. Chrome may be reporting an error likeerror: -105 (ERR_NAME_NOT_RESOLVED) – ndemarco – 2016-01-13T14:25:12.953

4

Answering my own question:

There was a rootkit virus attempting to redirect google.com. I was able to download a rootkit removal tool which found and removed the threat.

gregm

Posted 2012-02-21T00:54:03.540

Reputation: 41

8What was the rootkit (and removal tool)? – Synetech – 2012-02-27T01:09:31.087