Jump to content

static network config in debian9 and newer armbian images


dolphs

Recommended Posts

Hi - I flashed a new nanopineo2 with debian9 ( Armbian_5.44.180510_Nanopineo2_Debian_stretch_next_4.14.40 ) and set this to stable build before updating to latest "stable".

Next step after reboot is to configure my static network ( eth0 ), but here things tend to be a bit different than previous flash ?

Previously in advanced I edited /etc/network/interfaces to add my DNS-servers but in this build it seems " Network is managed by NetworkManager " so I instea I used " nmtui " to set these for "Wired Connection 1". Unfortunately I still see in /etc/resolv.conf : " nameserver 8.8.8.8 " first before my entries. I like to get rid of this nameserver but I am unable to find it. Anyone please? TiA!

Link to comment
Share on other sites

On my NanoPi Neo2 with ARMBIAN 5.46.180603 nightly Debian GNU/Linux 9 (stretch) 4.14.47-sunxi64

the /etc/resolv.conf is controlled by the NetworkManager via nmtui.

So the content of my file looks like:

 

root@nanopineo23(192.168.6.23):~# more /etc/resolv.conf

 

# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
#     DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN
nameserver 192.168.6.3
search GUIDO
 

Check the templates for resolv.conf at /etc/resolvconf/resolv.conf.d/ :

 

ls -1 /etc/resolvconf/resolv.conf.d/

base

head

original

tail

 

in the file /etc/resolvconf/resolv.conf.d/original I have these lines:


# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
#     DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN
nameserver 8.8.8.8
 

But this should be replaced by the NetworkManager to the Dynamic resolv.conf which do you could see at the top.

 

 

Link to comment
Share on other sites

thanks a lot, this helped a lot.

I managed now by cleaning file " head " as that contained the google DNS entry I was looking for and is the primary entry.  

The tool " nmtui " still can be used to add DNS entries, but instead I believe these can be added to " head " so no need to use the text user interface.

thanks again

Link to comment
Share on other sites

isn't jessie deprecated now anyway, since stretch came to life officially last year.

I am aware many are still on jessie as it will be maintained till 2020?

Anyway, DNS I assume in Stretch either " /etc/resolvconf/resolv.conf.d " or as it used to be ( thru /etc/network/interfaces ) in Jessie.

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines