Disabling DNF modules on Fedora 31 so they don't mess up package updates

August 10, 2020

Fedora 31 DNF modules (and probably Fedora 32 ones as well) are currently broken, as covered here and here. Fedora is not insuring that DNF modules that claim to be the 'latest' (for example ripgrep) have versions of their packages that are as recent as the non-modular packages (the ripgrep module has 11.0.2; Fedora 31 has 12.0.1), and the mere existence of a DNF module for something will block updates, even if you have not enabled the module. The only way out is to disable (or ignore) DNF modules.

If you want to temporarily ignore DNF modules to update your system to the latest versions of packages available in the main Fedora 31 repository, the following (from my first entry) appears to work:

dnf --setopt=updates.module_hotfixes=true --setopt=fedora.module_hotfixes=true update

In my second entry I thought that removing everything from /etc/dnf/modules.d would prevent problems. This turns out to not be the case. If you want to completely disable DNF modules, you need to either edit /etc/yum.repos.d/fedora-modular.repo to change 'enabled=1' to 'enabled=0', or remove the file entirely. I would edit the file, as that probably has a higher chance to survive package updates of the fedora-repos package. I believe that you can also do this with 'dnf config-manager --set-disabled fedora-modular', but I'm the kind of person who uses an editor here.

(Fedora has repo files in /etc/yum.repos.d for reasons of historical compatibility and avoiding flag days where all repo files have to move, one way or another. It amuses me sometimes.)

I don't yet know if upgrading Fedora with DNF keeps modules disabled. I suspect not and that I'll have to go back in to clean things out after I upgrade to Fedora 32 one of these days. After my experiences with modules to date, I have no intentions of ever having them doing anything on any of my Fedora machines until and unless Fedora gives me no choice in the matter.

I hope that this is the last entry I have to write about DNF modules. There's more that I could say about this mess but I'd rather not spend more time on it.

Written on 10 August 2020.
« Unix options conventions are just that, which makes them products of culture
How Go 1.15 improved converting small integer values to interfaces »

Page tools: View Source, Add Comment.
Search:
Login: Password:
Atom Syndication: Recent Comments.

Last modified: Mon Aug 10 22:36:49 2020
This dinky wiki is brought to you by the Insane Hackers Guild, Python sub-branch.