2

Everytime that I start my computer, my DNS does not work. In /etc/resolv.conf I see:

# Generated by Connection Manager
nameserver ::1
nameserver 127.0.0.1

I see that /etc/resolv.conf is a soft link to /run/connman/resolv.conf

With this configuration, my DNS does not work (example: cannot surf the web with Chrome/Firefox, dig google.com gives me no IP, and ping gives me "Name or service not known"). So, I manually change the nameserver ::1 with some valid IP (like 1.1.1.1 or 8.8.8.8). I need to do this every time that I turn on my computer.

I don't know if connman (Intel Connection Manager daemon) comes preinstalled in Ubuntu 17.10, or I have installed it when trying to install a VPN client. Searching on the web, it seems that I don't have a standard configuration. So, I tried stopping the service, but then I lose my connections and don't see the available networks in the (NetworkManager?) Applet.

I can see that connmand is listening on port 53 (but does not resolve well), and systemd-resolve is also listening on port 53 (but attached to 127.0.0.53):

sudo netstat -tulpn | grep ":53 "
tcp        0      0 127.0.0.1:53            0.0.0.0:*               LISTEN      21159/connmand      
tcp6       0      0 ::1:53                  :::*                    LISTEN      21159/connmand      
udp        0      0 127.0.0.1:53            0.0.0.0:*                           21159/connmand      
udp        0      0 127.0.0.53:53           0.0.0.0:*                           1451/systemd-resolv 
udp6       0      0 ::1:53                  :::*                                21159/connmand

If I execute systemd-resolve --status, it gives me the correct DNS.

Relinking /etc/resolv.conf to /run/systemd/resolve/resolv.conf also solves my problem.

So, how can I disable connman (at least as the DNS proxy) and reenable systemd-resolve? Is connman installed by default on Ubuntu 17.10?

0

Sorry, it was as easy as:

1) removing connman:

sudo apt remove connman

2) deleting resolv.conf:

sudo rm /etc/resolv.conf

3) relinking to /run/systemd/resolve/resolv.conf

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

The last 2 steps were necessary because without the /etc/resolv.conf managed by connman, NetworkManager managed it, putting "127.0.1.1" as DNS server (and there were no server listening there).

The man page of NetworkManager says that all it needs to let systemd-resolve manage resolve.conf, is to make a softlink to the resolv.conf file under any of the systemd directories.

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

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