Skip to content

Categories:

The mystery of the Mac OS (10.6) DNS resolver

/etc/dnsmasq.conf on the gateway which is also pushed as sole DNS server:

address=/wiki.inter-actief.utwente.nl/10.10.3.17


Switch:~ daenney$ host wiki.inter-actief.utwente.nl
wiki.inter-actief.utwente.nl has address 10.10.3.17

Switch:~ daenney$ ping wiki.inter-actief.utwente.nl
PING zwarejongens.vereniging.utwente.nl (130.89.55.65): 56 data bytes

It seems that the ‘host’ command uses libc which uses nss which uses ‘resolv.conf’ resulting in the use of DNS server ‘192.168.1.1′ on the host command but the ping command seems to get its DNS-servers from somewhere else.

So, did Apple just do something funky, alter libc somehow or what the flying f*ck?

Posted in random.


2 Responses

Stay in touch with the conversation, subscribe to the RSS feed for comments on this post.

  1. Greg says

    Funny.. I run into the exact same problem :-(

  2. Daenney says

    Actually, I found out what happens.

    The culprit is the infamous OS X utility called dscacheutil, which, amongst other things, caches DNS entries.
    The fix? dscacheutil -flushcache and try again.



Some HTML is OK

or, reply to this post via trackback.