resolv.conf symlink breaks with /run/NetworkManager/resolv.conf disappearing
The module affected
NetworkManager
What is the action to reproduce the bug?
I boot a Pi4 system without ethernet attached and wifi via rfkill after boot (nmcli r wifi off)
Attaching a USB modem gives a wwan device which can be setup as NM connection:
nmcli connection add type gsm ifname '*' con-name 'Oniro-WWAN' apn '
web.vodafone.de' connection.autoconnect yes
Connection 'Oniro-WWAN' (10979f57-a3d4-4290-90fe-7a36990a396b) successfully added.
What is the result you see?
The connection gets established, but address resolution does not work:
root@eddie-server:~# ping google.com
ping: bad address 'google.com'
root@eddie-server:~# ping 8.8.8.8
PING 8.8.8.8 (8.8.8.8): 56 data bytes
64 bytes from 8.8.8.8: seq=0 ttl=113 time=116.157 ms
64 bytes from 8.8.8.8: seq=1 ttl=113 time=21.811 ms
Coming from the fact that the /etc/resolv.conf symlinks to /run/NetworkManager/resolv.conf (through one indirection) which does not exist.
root@eddie-server:/etc# ls -al /etc/resolv.conf
lrwxrwxrwx 1 root root 31 Mar 9 2018 /etc/resolv.conf -> /etc/resolv-conf.NetworkManager
root@eddie-server:/etc# ls -al /etc/resolv-conf.NetworkManager
lrwxrwxrwx 1 root root 33 Mar 9 2018 /etc/resolv-conf.NetworkManager -> ../run/NetworkManager/resolv.conf
root@eddie-server:/etc# ls -al ../run/NetworkManager/resolv.conf
ls: ../run/NetworkManager/resolv.conf: No such file or directory
I already disabled systemd-resolvd and made sure it does not start up after a reboot, but this did yield no change.
What is the result you expect?
Working resolv.conf symlink and address resolution
Frequency?
Always, but with extra hardware (usb wwan modem)
Tested version
root@eddie-server:~# cat /etc/os-release
ID=oniro-linux-blueprint-eddie
NAME="Oniro Project EDDIE Blueprint Linux Distro"
VERSION="1.99.99 (dev)"
VERSION_ID=1.99.99
PRETTY_NAME="Oniro Project EDDIE Blueprint Linux Distro 1.99.99 (dev)"
DISTRO_CODENAME="dev"
Do you know any workaround of this issue?
Manually setting up resolv.conf
Do you have a fix for this issue?
No