Ubuntu – DNS issues with Cisco VPN (vpnc) on 15.04

15.04dnsnetwork-managervpn

I'm having issues with DNS resolution of on-network servers. I can get them directly via IP address, however DNS lookup fails.

Notes:

  • I configured the VPN connection via NetworkManager.
  • The connection is established correctly and the routes look good, but DNS still fails.
  • The configuration is identical to a working configuration on Lubuntu 15.04 where it works flawlessly. It just won't work in standard Ubuntu.
  • My company does not use "split tunneling."

Things I have tried in all possible combinations (all have been reverted):

  • Disable dnsmasq in NetworkManager.conf
  • Manually specify DNS servers / Search in VPN configuration
  • Set managed=false in NetworkManager.conf to true (per source)

Any ideas?

Best Answer

The problem was that all of our on-network servers are named *.local and this is inherently incompatible with Avahi. More reading.

The solution I used was to edit /etc/nsswitch.conf and change the following line:

hosts: files mdns4_minimal [NOTFOUND=return] dns

To:

hosts: files dns mdns4_minimal [NOTFOUND=return]