revolve.conf issue??

Here you can discuss every aspect of Debian. Note: not for support requests!

revolve.conf issue??

Postby Munty Scruntfundle » 2019-03-27 16:17

I'm trying to find a solution to a DNS problem, my Banana pi running debian can't see the outside world. This is a stretch version, 9 something I think.

I am root.
I CAN nano /etc/resolve.conf, but I can't save, No such file or directory.
I can ls the file, but can't cat it, No such file or directory.
I can't touch the file, No such file or directory.
I can't chmod the file.
I can't chown the file.

lrwxrwxrwx 1 root root 35 Jun 11 2018 resolv.conf -> /var/run/NetworkManager/resolv.conf

Exactly the same outcome trying to use /var/run/NetworkManager/resolv.conf.

I have tried adding the dns-nameserver under the eth0 details in /etc/network/interfaces but this doesn't appear to do anything.

Could someone please suggest a couple of ideas? I can't even update the bloomin thing!

I'm running headless with SSH so the local network settings are fine. I can't get to the desktop.

Many thanks.
Munty Scruntfundle
 
Posts: 54
Joined: 2018-11-27 16:53

Re: revolve.conf issue??

Postby roseway » 2019-03-27 17:47

The file is called resolv.conf, not resolve.conf. In order to edit it you need to have root privilege.

When you say that you CAN nano /etc/resolve.conf, all that means is that nano will open a new editing session for that non-existent file. You won't be able to save it unless you have root privilege.
Eric
User avatar
roseway
 
Posts: 1509
Joined: 2007-12-31 22:50
Location: Kent, UK

Re: revolve.conf issue??

Postby Head_on_a_Stick » 2019-03-27 17:53

Munty Scruntfundle wrote:lrwxrwxrwx 1 root root 35 Jun 11 2018 resolv.conf -> /var/run/NetworkManager/resolv.conf

Try:
Code: Select all
file /etc/resolv.conf

The file is a symlink and NetworkManager is controlling the content so to change it alter the settings in that program.

If you want to use /etc/network/interfaces instead then delete the symlink and let ifupdown create a new one for you.
User avatar
Head_on_a_Stick
 
Posts: 10346
Joined: 2014-06-01 17:46
Location: /dev/chair

Re: revolve.conf issue??

Postby p.H » 2019-03-27 18:43

Munty Scruntfundle wrote:I have tried adding the dns-nameserver under the eth0 details in /etc/network/interfaces but this doesn't appear to do anything.

Of course not. dns-nameserver(s) options have an effet only if resolvconf is installed and manages resolv.conf. But it does not, as can be seen in the symlink target /var/run/NetworkManager/resolv.conf. If you are using several DNS sources (NetworkManager, /etc/network/interfaces...) I recommend that you install resolvconf.

Note : On a modern Debian system /var/run is also a symlink pointing to /run, and /run is mounted as a tmpfs (memory-based temporary filesystem) which is volatile. If NetworkManager is not running, /run/NetworkManager/ does not exist so /run/NetworkManager/resolv.conf cannot be created.
p.H
 
Posts: 1027
Joined: 2017-09-17 07:12

Re: revolve.conf issue??

Postby Munty Scruntfundle » 2019-03-27 18:54

After A LOT of messing around with all sorts of guff, here's what finally worked.

Disable NetworkManager. Henceforth known as NetowkBallsupManager.
Stop the service
Disable Systems.resolve. See above for similar renaming convention.
Stop the service.

Delete /etc/resolv.conf
Create /etc/resolv.conf however you want, add the first line nameserver=x.x.x.x #Repalce xxxx as needed.

www ping perfect.

Why are these 2 additions to debian installed when they both obviously conflict with each other and prohibit you making manual changes on a system that may very well be run headless? At the very least turn the damn things off as default? No? Just me?

I hope someone else finds this helpful.
Munty Scruntfundle
 
Posts: 54
Joined: 2018-11-27 16:53

Re: revolve.conf issue??

Postby Head_on_a_Stick » 2019-03-27 19:03

Munty Scruntfundle wrote:Disable systemd-resolved [corrected]

^ No need to do this, systemd-resolved will *not* modify /etc/resolv.conf unless it is symlinked to one of systemd's provided resolver files, otherwise it merely accepts whatever nameservers are listed in /etc/resolv.conf and continues to provide the resolvectl(1) utility.

Munty Scruntfundle wrote:Why are these 2 additions to debian installed when they both obviously conflict with each other and prohibit you making manual changes on a system that may very well be run headless?

They don't conflict, the behaviour is determined by the presence (or not) of symlinks and their origin.

For the record, NetworkManager can be controlled from the command line and so is suitable for use in headless systems, see nmcli(1) for instructions.
User avatar
Head_on_a_Stick
 
Posts: 10346
Joined: 2014-06-01 17:46
Location: /dev/chair

Re: revolve.conf issue??

Postby tynman » 2019-03-30 03:00

Why are these 2 additions to debian installed when they both obviously conflict with each other and prohibit you making manual changes on a system that may very well be run headless? At the very least turn the damn things off as default? No? Just me?

I assume this refers to the resolve service and to Network-Manager. I think it is worth noting that neither package is installed in Debian by default. If not installed, they don't need to be turned off.
tynman
 
Posts: 104
Joined: 2016-05-03 19:48
Location: British Columbia, Canada


Return to General Discussion

Who is online

Users browsing this forum: No registered users and 4 guests

fashionable