Better handling of when to use local_dns.