Open ravanelli opened 9 months ago
What you are experiencing is probably systemd-resolved that's overwritting the file because DNSStubListener=yes
is the default (see /etc/systemd/resolved.conf
). If you want to add some entries I think you can set them in the NetworkManager keyfile (which I think then passes them to systemd-resolved) or you can add a snippet to /etc/systemd/resolved.conf
or new file in /etc/systemd/resolved.conf.d/mydns.conf
I think.
I think the issue we were seeing was that we couldn't get DNS resolution to internal hostnames when using systemd-resolved, even though the VPN DNS servers were listed in the systemd-resolved stub. So we ended up just un-symlinking, disabling systemd-resolved and manually defining /etc/resolv.conf
.
so you disabled systemd-resolved.service
, but NetworkManager
was still somehow removing your settings from /etc/resolv.conf
that you had set statically?
We tried a lot of things, as:
One of the last times I edited it I did:
sudo systemctl disable systemd-resolved `to remove the links created`
sudo systemctl stop systemd-resolved
rm /etc/resolv.conf
Recreated it with the changes I needed
sudo systemctl enable systemd-resolved
sudo systemctl start systemd-resolved
I also tried it via resolvectl
If you are re-enabling systemd-resolved
with DNSStubListener=yes
set then you'll continue to have the problem. If you want to set some DNS manually I would suggest putting some entries in either the NM keyfile with the other settings (there are some examples of this in our docs) OR set it in a new /etc/systemd/resolved.conf.d/mydns.conf
file directly.
I can hop on a screenshare sometime this week if that would be helpful.
Describe the bug
if the instance is rebooted the Networking Manager is overwriting the
/etc/resolve.conf
Reproduction steps
Launch an instance using 'Fedora CoreOS 39.20231101.1.0' in PowerVs, ~change~ update (see comments)
/etc/resolve.conf
reboot the systemExpected behavior
Not overwriting done
Actual behavior
if the instance is rebooted the Networking Manager is overwriting the
/etc/resolve.conf
System details
PowerVs
Butane or Ignition config
Additional information
No response