Apple MAC : unable to ping but can dig or nslookup

Published by

Posted on July 19, 2014

Network Setup: One wireless router , One standard router, 24 port switch, and internal dns server. Also two subnets on the network

Issue: Devices ( Mac ) connected to the second subnet are unable to ping internal host records.

Solution : On the wireless network , we had to update the DHCP server to only include the internal dns server ip address. We initially had it to include our internal and googles public as a secondary. For some reason ping was using the secondary from our mac systems. we also disable dns relay on the wireless router. DNS Relay was forcing all dns queries to the gateway.

After which you will need to clear the dns cache

Mac
sudo launchctl unload -w /System/Library/LaunchDaemons/com.apple.mDNSResponder.plist
sudo launchctl load -w /System/Library/LaunchDaemons/com.apple.mDNSResponder.plist

Other possible solutions
http://apple.stackexchange.com/questions/24018/dns-lookups-fail-with-e-g-ping-but-work-with-host
http://www.makingitscale.com/2011/fix-for-broken-search-domain-resolution-in-osx-lion.html
https://github.com/michthom/AlwaysAppendSearchDomains


About the Author