Ubuntu 18
Ubuntu 18
default package management system for Red Hat Enterprise Linux and its derivative
distributions for many years. It has since been replaced by dnf package manager,
which is a fork of yum that has been developed to be faster, more efficient, and have
better documentation. Modern Linux distros only use yum as a compatibility layer for
dnf, in order to accomodate legacy Bash scripts and old commands.
Most likely, you ended up on this page because you attempted to execute a yum
command that you found online and got an error. But this is because you are not using
a Linux distro that utilizes the yum package manager. Find out what your default
package manager is (e.g., Ubuntu uses apt, and Arch uses pacman, etc), and instead
use that package manager to install the software.
In this tutorial, we will go over the step by step instructions to install yum and dnf on
on all major Linux distros. Then, we will go over a few commands and examples to
help you get started installing packages with your new package manager.
Or to install dnf:
This will also install dnf as a dependency (if not already installed) and gives access to
the yum4 command. This just takes old yum commands and sends them straight to dnf
for you.
$ yay -s yum
There are plenty of other dnf and yum commands, and you can view them in the
manual:
$ man dnf
and
$ man yum
To install an RPM from the yum repository, run the following command:
# yum install rpm_name
For the yum update or yum remove command, if you specify an RPM that is in the
exclusion list defined earlier, the command will fail.