(Mint 19 Beta) dns-nameservers term no longer works

Questions about Wi-Fi and other network devices, file sharing, firewalls, connection sharing etc
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
Altersoundwork

(Mint 19 Beta) dns-nameservers term no longer works

Post by Altersoundwork »

Hi all,

I'm wondering if I'm doing something wrong as I'd imagine it wouldn't be just me with this issue and yet, I couldn't find an answer.

So I'm using 18.3 KDE as my daily driver and I'm testing out 19 Mate as the soon-to-be replacement. My /etc/network/interfaces file looks like this on 18.3

Code: Select all

auto lo
iface lo inet loopback

dns-nameservers 192.168.4.100

auto ens33

iface ens33 inet static
address 192.168.4.239
netmask 255.255.255.0
gateway 192.168.4.100
This works fine on Mint 18.3 KDE but does not on 19 Mate (no internet connectivity). When I check the network settings through the GUI on Mint 19, I see that the DNS Nameservers haven't been saved (although everything else within the etc/network/interfaces file is shown here so my question is, has the the way the dns-nameservers term on etc/network/interfaces work been changed? And if so, what's the new way of doing it? I'd rather be able to do it through terminal rather than depend on the gui.

Thanks in advance! :)
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
JeremyB
Level 21
Level 21
Posts: 13724
Joined: Fri Feb 21, 2014 8:17 am

Re: (Mint 19 Beta) dns-nameservers term no longer works

Post by JeremyB »

Yes networking has changed, see https://netplan.io/
I haven't done anything with netplan yet
User avatar
catweazel
Level 19
Level 19
Posts: 9763
Joined: Fri Oct 12, 2012 9:44 pm
Location: Australian Antarctic Territory

Re: (Mint 19 Beta) dns-nameservers term no longer works

Post by catweazel »

JeremyB wrote: Fri Jun 15, 2018 5:43 am Yes networking has changed, see https://netplan.io/
I haven't done anything with netplan yet
Prepare for a mountain of posts about network issues.
"There is, ultimately, only one truth -- cogito, ergo sum -- everything else is an assumption." - Me, my swansong.
User avatar
catweazel
Level 19
Level 19
Posts: 9763
Joined: Fri Oct 12, 2012 9:44 pm
Location: Australian Antarctic Territory

Re: (Mint 19 Beta) dns-nameservers term no longer works

Post by catweazel »

Altersoundwork wrote: Fri Jun 15, 2018 5:23 am

Code: Select all

auto ens33
Please post the output of this command:

cat /proc/net/dev | awk '{print $1}'
"There is, ultimately, only one truth -- cogito, ergo sum -- everything else is an assumption." - Me, my swansong.
Altersoundwork

Re: (Mint 19 Beta) dns-nameservers term no longer works

Post by Altersoundwork »

Firstly, thank you all for your replies. As I feared, it's due to a change.

So I found a solution that doesn't require playing with netplain.

1: Run the command:

Code: Select all

sudo apt install resolvconf
2: Edit /etc/resolvconf/resolv.conf.d/tail and add the nameser/s of choice (one per line). In my specific case and for the sake of an example it is as follows:

Code: Select all

nameserver 192.168.4.100
This line/s will be added at the end of /run/resolvconf/resolv.conf at boot.

Original source: "Oscar1919" -> https://askubuntu.com/questions/1012641 ... ect=1&lq=1

*-------------------*

@catweazel

Not sure if this applies any longer after the aforementioned "solution" but:

Code: Select all

xxxx@vm-mint19-mate:~$  cat /proc/net/dev | awk '{print $1}'
Inter-|
face
lo:
ens33:
As for Netplain, the examples shown on the website seem pretty straight forward, though I'd add this here for anyone that wants to give it a go -> https://netplan.io/examples
ewaldc
Level 1
Level 1
Posts: 9
Joined: Mon Aug 14, 2017 2:35 am

Re: (Mint 19 Beta) dns-nameservers term no longer works

Post by ewaldc »

Another simple solution to fix DNS lookup without the need to install resolvconf...
Systemd maintains /run/systemd/resolve/resolv.conf with the proper DNS information as per the new systemd-resolve service.
However /etc/resolv.conf is a symbolic link to ../run/resolvconf/resolv.conf which resolves all names via 127.0.0.53.
This breaks queries from root zone (.), like local server lookups such as nslookup mylocalserver (see https://github.com/systemd/systemd/issues/4621 and https://github.com/systemd/systemd/issues/5897
It also causes issues with applications that lookup DNS servers via /etc/resolv.conf since all they find is 127.0.0.53.

This worked perfectly for me and did not break systemd services.

Code: Select all

sudo mv /etc/resolv.conf /etc/resolv.conf.orig
sudo ln -s /run/systemd/resolve/resolv.conf /etc/resolv.conf
Ewald
zorrek

Re: (Mint 19 Beta) dns-nameservers term no longer works

Post by zorrek »

LEGEND !

This worked for me.
Why is mint shipped broken?
I'm using the latest Mint 19 fully updated.
Before doing this, even though X had all the correct network information DNS simply failed.

Code: Select all

sudo mv /etc/resolv.conf /etc/resolv.conf.orig
sudo ln -s /run/systemd/resolve/resolv.conf /etc/resolv.conf
Ewald
speedsterharry

Re: (Mint 19 Beta) dns-nameservers term no longer works

Post by speedsterharry »

Hello,

I just want to chime in to say THANK YOU EWALD.
I was running into exactly the same problems as the OP and ewald's solution was exactly what I needed.
Saved me a fresh reinstall.
So again, thank you very very much ewald !
DarkgrayLord

Re: (Mint 19 Beta) dns-nameservers term no longer works

Post by DarkgrayLord »

Thanky you, Edward.

I had Cinnamon since 19.1, now upgraded to 19.3 and had this odd issue:
Everything worked for some time - and than (after 30-60min?) my network connection broke.
I had it pinned down to:

Code: Select all

ping 8.8.8.8
did reach the server, and nslookup only worked after pinning

Code: Select all

>server 8.8.8.8
each time. Nevertheless, the 8.8.8.8 wasn't sticky, even when disabling the automatic DNS in the network config and set it to 8.8.8.8 there...
dig would timeout every time, restarting the networking service was without effect. The only fix was a reboot - felt like Windows.

From what I understand, this is related, but: Why did the dns work for some time, and what did break it?

edit: not using the beta, despite the original topic
Locked

Return to “Networking”