Bug 2216807
| Summary: | upgrade to dnf5 fails because dnf is protected | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Product: | [Fedora] Fedora | Reporter: | Zbigniew Jędrzejewski-Szmek <zbyszek> | ||||||
| Component: | dnf5 | Assignee: | Evan Goode <egoode> | ||||||
| Status: | NEW --- | QA Contact: | |||||||
| Severity: | unspecified | Docs Contact: | |||||||
| Priority: | unspecified | ||||||||
| Version: | 39 | CC: | amatej, awilliam, egoode, jkolarik, nsella, petersen, pkratoch, rpm-software-management | ||||||
| Target Milestone: | --- | Keywords: | Triaged | ||||||
| Target Release: | --- | ||||||||
| Hardware: | Unspecified | ||||||||
| OS: | Unspecified | ||||||||
| Whiteboard: | |||||||||
| Fixed In Version: | Doc Type: | If docs needed, set a value | |||||||
| Doc Text: | Story Points: | --- | |||||||
| Clone Of: | Environment: | ||||||||
| Last Closed: | 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: | |||||||||
| Attachments: |
|
||||||||
Created attachment 1972130 [details]
dnf debugdata
Hi, what version of `libdnf` do you have installed? The protection of the `dnf` package was (unfortunately) hardcoded in libdnf until the most recent version, 0.70.1. I believe this issue should not affect users upgrading from Fedora 38 to Fedora 39 IF they remember to do a full update of F38 before upgrading to F39. But some Rawhide users may have to use `--skip-broken` or similar since not much time passed between (1) removing the hardcoded protection of dnf and (2) obsoleting DNF in favor of DNF 5. libdnf-0.70.0-1.fc39.x86_64 I removed dnf5, libdnf5, libdnf5-cli (*dnf5*), and this doesn't change anything. Is there a way to do the upgrade without calling rpm manually? I guess if not, we should at least document the rpm-based approach so people can upgrade their systems if they get into this situation. It is possible to override the protected packages. $ dnf update --setopt=protected_packages=, This clears all protected packages for the run. Setting "," to a list option empties it. Thanks Ales, I can confirm this works even for the protection of dnf. I am able to upgrade from dnf-4.15.1-1.fc39.noarch and libdnf-0.70.0-1.fc39.x86_64 straight to DNF 5 with that command. This bug appears to have been reported against 'rawhide' during the Fedora Linux 39 development cycle. Changing version to 39. |
Created attachment 1972129 [details] strace from dnf5 upgrade… Description of problem: I have a container which has dnf and dnf5 installed, and the 'dnf update' fails: $ rpm -q dnf dnf5 dnf-4.15.1-1.fc39.noarch dnf5-5.0.9-3.fc39.x86_64 $ sudo dnf upgrade dnf Last metadata expiration check: 1:08:36 ago on Thu Jun 22 09:42:16 2023. Error: Problem: The operation would result in removing the following protected packages: dnf (try to add '--skip-broken' to skip uninstallable packages) $ sudo dnf upgrade dnf5 Last metadata expiration check: 1:08:39 ago on Thu Jun 22 09:42:16 2023. Error: Problem: The operation would result in removing the following protected packages: dnf (try to add '--skip-broken' to skip uninstallable packages) $ sudo dnf upgrade Last metadata expiration check: 1:08:41 ago on Thu Jun 22 09:42:16 2023. Error: Problem: The operation would result in removing the following protected packages: dnf (try to add '--skip-broken' to skip uninstallable packages) I don't have /etc/yum/protected.d, and: $ cat /etc/dnf/protected.d/* # DNF is obsoleted in Fedora 39 by DNF 5 and should no longer be marked as protected. # dnf python3-dnf sudo systemd systemd-udev How reproducible: 100%. I'll attach strace and debugsolver output.