Hide Forgot
Description of problem: I'm doing some local testing of the upgrade path and want to test upgrading a package which is normally in a module. I have built my own local repo, but I still can't get dnf to upgrade the package: # cat /etc/yum.repos.d/TEST.repo [TEST] name=TEST baseurl=file:///var/tmp/p/n12 enabled=1 gpgcheck=0 # dnf install nbdkit-server --enablerepo=TEST --disableexcludes=all --disableexcludepkgs=all Updating Subscription Management repositories. Unable to read consumer identity This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register. Last metadata expiration check: 0:05:18 ago on Mon 29 Jul 2019 15:41:20 BST. Error: Problem: problem with installed package nbdkit-1.4.2-5.module+el8.0.0+3748+44021654.x86_64 - package nbdkit-server-1.12.1-2.el8.x86_64 conflicts with nbdkit < 1.12 provided by nbdkit-1.4.2-5.module+el8.0.0+3748+44021654.x86_64 - package nbdkit-server-1.12.1-2.el8.x86_64 conflicts with nbdkit < 1.12 provided by nbdkit-1.4.2-5.module+el8.1.0+3531+2918145b.x86_64 - conflicting requests - package nbdkit-1.12.1-2.el8.x86_64 is excluded - package nbdkit-1.4.2-5.module+el8.0.0+3748+44021654.x86_64 is excluded (try to add '--allowerasing' to command line to replace conflicting packages or '--skip-broken' to skip uninstallable packages or '--nobest' to use not only best candidate packages) There should be a "just do it" option to kill excludes. Version-Release number of selected component (if applicable): dnf-4.2.6-1.el8.noarch How reproducible: 100% Steps to Reproduce: 1. See above.
Set module_hotfixes=True to the repository configuration. Otherwise modular packages of the same name will overlay your packages. Alternatively add a modulemd for your locally built module into the YUM metadata of the repository so that DNF recognizes the packages as part of the module stream.
(In reply to Petr Pisar from comment #1) > Set module_hotfixes=True to the repository configuration. Otherwise modular > packages of the same name will overlay your packages. Can confirm this works, thanks. Is this documented somewhere? It's not part of the dnf man page.
dnf.conf(5) from dnf-data-4.2.7-2.el8.noarch documents module_hotfixes configuration option. But it's true than DNF does not document that packages from an active module stream overlays nonmodular packages.
Additional information can be found with `man dnf.modularity` (Requires dnf-4.2.7). Repo configuration module_hotfixes=True could be adjust from a command-line for a particular repository `--setopt=<repoid>.module_hotfixes=True` or for all repositories using `--setopt=*.module_hotfixes=True` (Requires dnf-4.2.7). Man pages were enhanced by https://github.com/rpm-software-management/dnf/commit/d2c509a2c7ff2db59670d083b06d4479e96451d3
dnf.modularity(7) should be linked from dnf(8). Preferably from the Module Command section.
Links will be added by https://github.com/rpm-software-management/dnf/pull/1453.
Adding module_hotfixes=True fixed my issue installing docker-ce on CentOS 8 The error was: (to help google) # yum install docker-ce Failed to set locale, defaulting to C Last metadata expiration check: 0:03:21 ago on Thu Sep 26 22:00:05 2019. Error: Problem: package docker-ce-3:19.03.2-3.el7.x86_64 requires containerd.io >= 1.2.2-3, but none of the providers can be installed - cannot install the best candidate for the job - package containerd.io-1.2.2-3.3.el7.x86_64 is excluded - package containerd.io-1.2.2-3.el7.x86_64 is excluded - package containerd.io-1.2.4-3.1.el7.x86_64 is excluded - package containerd.io-1.2.5-3.1.el7.x86_64 is excluded - package containerd.io-1.2.6-3.3.el7.x86_64 is excluded (try to add '--skip-broken' to skip uninstallable packages or '--nobest' to use not only best candidate packages)
I must mentioned that using module_hotfixes=True is a dangerous override that could easily destroy your system. It allows combination of packages that were built in completely different environment or with incompatible setting.
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2020:1823