Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

Can't resolve host name

This is similar to another thread under OS X 10.4, but I followed it to its conclusion to adding my DNS domain in the search, and it was already there (supplied by my server). I still can't resolve from my Mac.

I have a Windows network (the Macbook is my first of many Macs). When I ping either host name, or host name with fully-qualified domain name (FQDN), I get:

Jay-Imermans-MacBook-Pro:~ jimerman$ ping Wkstn8
ping: cannot resolve Wkstn8: Unknown host
Jay-Imermans-MacBook-Pro:~ jimerman$


If I go to System Prefs > Network > Advanced > DNS, my Windows server appears by IP address, and the search domain is correct.

All of my PCs can resolve host names no problem. The Windows server is the only DHCP server on the network (the wi fi router has DHCP disabled).

Hopefully someone will have an idea?

Macbook Pro, Mac OS X (10.6.2)

Posted on Dec 8, 2009 7:25 PM

Reply
15 replies

Dec 9, 2009 12:59 PM in response to Sideways

Thanks Paul. I actually resolve it by renewing DHCP too, but the problem never occurred before Snow Leopard, which makes me think that the system calls got screwed up somewhere along the way. I don't have multiple network locations, so it doesn't apply, although it's helpful to know about that being a potential problem.

Thanks for the response!

Regards,

Chris

Dec 9, 2009 11:02 AM in response to direwolf8

I frequently have this problem but have a solution, at least to how it manifests on my MBP. The problem occurs for me when I work on a client site who uses DHCP for client laptops. When I go home and plug into my home LAN, the DNS servers and domain list from home router cannot override the settings from the work site which remain. The way to check this is to open network preferences, click on your network connection type (LAN or Airport) then use the advanced button. Now select the DNS tab. If the entries for dns servers and domain name appear in bold font they are probably wrongly persisted ones.
Either use a DHCP renew to clear (and/or) if that doesnt work, manually select the entries and press the minus key to remove them. Once the entries are gone try a dhcp renew and the correct values should appear in read only colour.
Also be aware that there is another issue where you may have set DNS entries in another network location, which then override your current location. Only solution there is to cycle through the Advanced / DNS tab for each location and delete incorrect entries manually before recycling DNS.

Hope that helps,

Paul

Dec 9, 2009 11:41 PM in response to Jay Imerman

Have the same problem. 10.6.2

nslookup is able to resolve host names
ping is NOT able to resolve host names
non of the browsers are able to resolve host names
Skype will work just fine, including voice calls

Tried DHCP renew, tried putting in public DNS servers (Google), deleting them - nothing helps.

The only solution is to restart my computer, than everything works just fine.

May happen even when I close my computer for a while, open it up again, and need to restart it to connect to Internet correctly. Happens both at home (D-Link Wifi router), and at work (variety of LinkSys routers).

Never happened to me before, even on Snow Leopard, but started showing up regularly now.

Dec 10, 2009 6:37 AM in response to cgiacomi

Argh - sorry about that.

If nslookup can resolve addresses but Mac OS X routines cannot, the problem most likely lies in the list of DNS servers being provided either manually or via DHCP.

Whether due to a bug or design, Snow Leopard occasionally alters the order in which it will consult DNS servers if more than one is listed. This is non-intuitive and different from how BIND-based programs like nslookup work.

For example, say you specified DNS servers in this order:

1.2.3.4
5.6.7.8

BIND-based utilities like nslookup would always use 1.2.3.4 for lookups, using 5.6.7.8 only if queries to 1.2.3.4 failed.

However for whatever reason, Snow Leopard's mDNS resolver, which is responsible for all non-BIND DNS lookups, will occasionally direct all queries to 5.6.7.8. If 5.6.7.8 is configured such that it gives a NXDOMAIN response to a query 1.2.3.4 could resolve, DNS resolution will fail in the manner you've described.

Jan 7, 2010 6:39 PM in response to Sideways

Had a similar problem, and this solved it. Thanks!
. Registered domain with one registry service A, which assigned an IP address #1
. Created hosting account with another company B, which gave me a different IP address #2 (It was a big PIA to hook up the domain with the IP address; next time will get domain registration and hosting from one place)
. Transferred the domain from A to B
. Uploaded content to web site at B (from DreamWeaver, via ftp, to ftp.mydomain)
. Tried to browse new site at B; but got to old site at A
. After some hours (I understand that these DNS changes take time), browser went to site at company B, but got standard page "this domain is parked here at B" instead of my uploaded home page
. Clearing browser caches (Firefox and Safari) and restarting browsers made no difference
. Reboot made no difference
. I tried our 2 other computers, both Windows: they correctly accessed my home page at address #2
. "nslookup" resolved to correct IP address #2, but "ping" and "traceroute" pinged the old address #1!
. System Preferences > Network > Advanced > TCP/IP > "Renew DHCP Lease" fixed it: now ping and browsers go to my site on address #2.

Mar 24, 2010 6:30 PM in response to Dogcow-Moof

Thank you, thank you, thank you!

I've been living with this for a while now (at least since 10.5.5), and didn't take the time to research it. I would either just live with it, or reboot to fix it for a while.

What happens to me is that I run my own DNS server and DHCP server on an OpenBSD box that also acts as router/gateway/firewall. Well, I've been serving up 3 DNS servers via DHCP for a while; mine, and two that my ISP runs just in case. Mine was always primary, so should always handle requests. Usually it worked. Before having my MBP Unibody, I had an XP box which never had any DNS issues with the same OpenBSD box.

So, to resolve it, I removed the external DNS servers from the DHCP configuration. Now, it works!

What saddens me is that it seems that as time goes on, Apple breaks more and more standard *NIX functionality. DNS resolution has standards which state that you should only use backup DNS servers if the primary is unavailable. I don't believe earlier versions of OS X had these problems. I used to have a PB Ti and never had these issues, with the same DNS/DHCP configuration. They also broke their mail client when it comes to relaying email through an SSH tunnel. It worked fine in 10.1, but broke in 10.2 and onward. I haven't checked in a while, but I wouldn't be at all surprised if it were still broken.

One of the reasons I like OS X is that it's based on UNIX, not something proprietary. I just wish they'd quit making their version proprietary, thus ignoring standards. Stop being like Micro$oft, already! 🙂

Thanks again.

Can't resolve host name

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.