Bug 1891847

Summary: systemd-246.6-3.fc33: /etc/resolv.conf should not be overwritten unconditionally
Product: [Fedora] Fedora Reporter: fedora.dm0
Component: systemdAssignee: systemd-maint
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 33CC: fedoraproject, filbranden, flepied, lnykryn, msekleta, praiskup, pslama, ssahani, s, systemd-maint, yuwatana, zbyszek, z
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: systemd-246.7-2.fc33 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-12-10 01:15:24 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description fedora.dm0 2020-10-27 14:12:23 UTC
Description of problem:
The systemd RPM postinstall scriptlet destroys the existing /etc/resolv.conf to symlink it to the systemd-resolved stub resolver version.  This breaks DNS in two different scenarios for me.

 1. Running the Fedora 33 container image in nspawn results in /etc/resolv.conf being copied from the host as usual, but then installing the systemd RPM removes it.  Since resolved isn't running, DNS is broken.

 2. I usually have DNSStubListener=no in /etc/systemd/resolved.conf (when I remember it exists), so even when I'm running systemd-resolved, the stub listener is not available.

Version-Release number of selected component (if applicable):
systemd-246.6-3.fc33

How reproducible:
Always

Steps to Reproduce:
1. Enter the Fedora-Container-Base-33 image with nspawn
2. dnf -y install systemd

Actual results:
All further attempts at networking fail due to broken DNS.

Expected results:
I should be able to install the systemd RPM and continue having networking.

Additional info:
I just need a way to specify that the existing /etc/resolv.conf should not be destroyed.

Comment 1 Pavel Raiskup 2020-11-09 09:20:47 UTC
Can you please add the link to the fix here?

Comment 3 Fedora Update System 2020-12-08 19:43:54 UTC
FEDORA-2020-3616681a70 has been submitted as an update to Fedora 33. https://bodhi.fedoraproject.org/updates/FEDORA-2020-3616681a70

Comment 4 Fedora Update System 2020-12-09 02:21:05 UTC
FEDORA-2020-3616681a70 has been pushed to the Fedora 33 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2020-3616681a70`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2020-3616681a70

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 5 Fedora Update System 2020-12-10 01:15:24 UTC
FEDORA-2020-3616681a70 has been pushed to the Fedora 33 stable repository.
If problem still persists, please make note of it in this bug report.