I set DNS servers on my PC to my local DNS caching server (, and,

Wired interface settings - DNS in IPv4 tab

Resolution on local DNS zone (.local) does not work. It works only when I force dig tool to use local server.

specifying server to dig in command line

Could you please help me set up a custom DNS server?

  • Seems that DNS works in firefox but ping command still cannot resolve my .local domain. – Richardds Jul 18 '18 at 7:16

My system consists of Ubuntu Desktop and a lot of additional server software, like Bind, Apache, Postfix.
I had the same problem: The configuration network configuration inputs from the GUI (settings > network) did not go into /etc/resolv.conf. Also the inputs from netplan did not got into /etc/resolv.conf. With this solution dig and nslookup work correctly.

The symbolic link /etc/resolv.conf points actually to /run/systemd/resolve/stub-resolv.conf. After the following solution it points to /run/systemd/resolve/resolv.conf:

$ sudo rm /etc/resolv.conf 
$ sudo ln -s /run/systemd/resolve/resolv.conf /etc/resolv.conf

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.