sudo yum install dnf-plugins-core did the trick for me.
UPDATE: on el7, el8, el9 there is a better way
- when you try to execute
dnf config-manager -hit will tell you to trydnf install 'dnf-command(config-manager)'
# centos7
# rocky8
# rocky9
sudo dnf install 'dnf-command(config-manager)'
p.s. the high level solution is actually "try to execute the dnf config-manager -h and if the command fails then read the error message and try installing what the error message recommends".
dnf on CentOS 7.9?
How to resolve "dnf: command not found..." problem on fedora 39
Is dnf supported on Centos 7? - Unix & Linux Stack Exchange
Can't install htop
sudo yum install dnf-plugins-core did the trick for me.
UPDATE: on el7, el8, el9 there is a better way
- when you try to execute
dnf config-manager -hit will tell you to trydnf install 'dnf-command(config-manager)'
# centos7
# rocky8
# rocky9
sudo dnf install 'dnf-command(config-manager)'
p.s. the high level solution is actually "try to execute the dnf config-manager -h and if the command fails then read the error message and try installing what the error message recommends".
$ sudo yum install yum-plugin-copr epel-release
Enable this repo
$ sudo yum copr enable ngompa/snapcore-el7
Install snapd
$ sudo yum install snapd
Enable snapd.socket
$ sudo systemctl enable --now snapd.socket
Install GNOME Software snap plugin, note that GNOME Software gets replaced in this step
$ sudo yum install gnome-software-snap
How do I run spotify...
run 'spotify' in your terminal Or search for the App in your applications
For more tips you can take a look at my Github repo: https://github.com/Winterhart/CentOS7-Setup
I hesitate to add this as an answer because I'm not sure it's a good way to fix it..
But anyway I had the same issue and 'fixed' it by adding module_hotfixes=true in /etc/dnf/dnf.conf.
https://dnf.readthedocs.io/en/latest/conf_ref.html tells us:
module_hotfixes
boolean
Set this to True to disable module RPM filtering and make all RPMs from the repository available. The default is False. This allows user to create a repository with cherry-picked hotfixes that are included in a package set on a modular system.
I'm not sure why this works in this case, I only have dnf on some sandbox servers and never got to the bottom of it.
You need to enable the repository, either by editing the .repo file to add enabled=1 or by running dnf config-manager --set-enabled postgresql
We are attempting to work through an upgrade process outlined by OracleLinux to migrate older CentOS 7.9 systems to OL8 instead of fully rebuilding them (we have near 100). However dnf is required to complete the elevate/leapp portion. It looks like dnf is no longer available in many (most) repos and some workarounds have gone offline.
tl;dr: Does anyone know of a repo hosting a copy of dnf 4.x+ that could be leveraged on CentOS 7.9?