resolv.conf questions
Ralf Mardorf
silver.bullet at zoho.com
Tue Aug 6 14:15:01 UTC 2019
On Tue, 6 Aug 2019 13:22:19 +0000, Mike Marchywka wrote:
>I think there are comment somewhere that you can replcae that( IIRC
>a symbolic link, [snip] with an actual file
IIRC I needed to do this, to use systemd-nspawn without the '--boot'
option [1], but apart from such an unusual case the link against run/
shouldn't matter and the content of the file likely gets automatically
overwritten [2], if it's a link to a file or a file.
[1]
[rocketmouse at archlinux ~]$ head -2 /mnt/moonstudio/etc/os-release
NAME="Ubuntu"
VERSION="16.04.6 LTS (Xenial Xerus)"
[rocketmouse at archlinux ~]$ ls -l /mnt/moonstudio/etc/resolv.conf
-rw-r--r-- 1 root root 94 Aug 5 23:08 /mnt/moonstudio/etc/resolv.conf
[rocketmouse at archlinux ~]$ cat /mnt/moonstudio/etc/resolv.conf
# Generated by resolvconf
domain localdomain
nameserver 192.168.1.1
nameserver fe80::1%enp3s0
[rocketmouse at archlinux ~]$ head -2 /etc/os-release
NAME="Arch Linux"
PRETTY_NAME="Arch Linux"
[rocketmouse at archlinux ~]$ ls -l /etc/resolv.conf
-rw-r--r-- 1 root root 94 Aug 5 23:08 /etc/resolv.conf
[rocketmouse at archlinux ~]$ cat /etc/resolv.conf
# Generated by resolvconf
domain localdomain
nameserver 192.168.1.1
nameserver fe80::1%enp3s0
[2]
"Normally the resolvconf program is run only by network interface
configuration programs such as ifup(8), ifdown, NetworkManager(8),
dhclient(8), and pppd(8); and by local nameservers such as
dnsmasq(8). These programs obtain nameserver information from some
source and push it to resolvconf."
- http://manpages.ubuntu.com/manpages/xenial/man8/resolvconf.8.html
Let alone that Colin already posted
"# 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"
So even if it's not in run/, a tmpfs that gets deleted at shutdown, the
content will be overwritten.
More information about the ubuntu-users
mailing list