Community Tutorials Fedora DNF vs YUM: What Changed on Fedora
DNF vs YUM: What Changed on Fedora
FEDORA

DNF vs YUM: What Changed on Fedora

SKYLINE Knowledge Base
Photo by Chris Ried on Unsplash

A field-tested, step-by-step guide. DNF vs YUM: What Changed on Fedora — prerequisites, the actual commands, verification, and links to related Fedora topics.

On modern Fedora and RHEL 8+, dnf is the package manager. The yum command still exists, but it is a symlink to dnf for muscle-memory. This article walks through what changed and the subset of dnf features that are genuinely new.

Prerequisites

  • Fedora 38+ or RHEL/Rocky/Alma 8/9 with sudo.

Step 1: Confirm yum is dnf

ls -la /usr/bin/yum
# /usr/bin/yum -> dnf-3   on Fedora 40
# /usr/bin/yum -> dnf     on RHEL/Rocky 9
type yum

Anything you type as yum install foo calls dnf install foo. Old scripts keep working.

Step 2: New commands you actually want

sudo dnf check-update            # exit 100 = updates available (same as yum)
sudo dnf upgrade --security -y   # security-only — yum had this; dnf is the same
sudo dnf needs-restarting -r     # 0 = no reboot needed
sudo dnf history list            # full transaction log
sudo dnf history undo 7          # roll back transaction 7
sudo dnf history info 7          # what was in transaction 7

Step 3: Modules (genuinely new in DNF 4+)

DNF added module streams — a way to install a non-default major version of a runtime without bringing in a competing package version conflict:

dnf module list nodejs
sudo dnf module enable -y nodejs:20
sudo dnf module install -y nodejs:20/common
node --version

# To switch to a different stream later:
sudo dnf module reset nodejs
sudo dnf module enable -y nodejs:22

yum had no module concept.

Step 4: Better dependency solver

dnf uses libsolv for SAT-style dependency solving, which is much faster than yum's old solver on large transactions. You feel this on system-wide upgrades — a dnf upgrade of 800 packages completes in a fraction of what yum took.

Step 5: Repository config — same files, friendlier tooling

The /etc/yum.repos.d/*.repo format is identical. The companion CLI changed though:

# Old:
sudo yum-config-manager --enable crb
# New (dnf-plugins-core required):
sudo dnf config-manager --enable crb

# Add a third-party repo (Microsoft, NodeSource, Docker, etc.)
sudo dnf config-manager --add-repo https://example.com/repo.repo

Step 6: When you still type yum

Two cases:

  1. Legacy automation — Ansible roles, Chef cookbooks, Salt states from 2017 that use yum modules. They still work because of the symlink.
  2. RHEL 7 is real EOL territory now (extended life-cycle support only) — that is the last release where yum is the actual binary. Anything you maintain on RHEL 7 is on a clock.

Verify

type yum                   # yum is /usr/bin/yum
readlink -f $(which yum)   # ends in dnf-3 or dnf
rpm -qa | grep ^dnf

Conclusion

If you typed yum, you used dnf. Modules and the libsolv solver are the two genuinely new things worth knowing. Otherwise, every command you knew transfers verbatim.

Next steps

SKYLINE Engineering

@skyline

The engineering team at SKYLINE Industrial Solutions. We publish field-tested guides drawn from real KSA and GCC deployments.

See author profile
SKYLINE engineering services

Need this implemented for you?

Reading is free — building it right takes a team. SKYLINE engineers ship Fedora for Aramco vendors, banks, hospitals and government agencies across Saudi Arabia. Talk to us before you start.

Aramco Approved Contractor ISO 9001 · ISO 27001 SAMA CSF aligned NCA ECC ready 247+ KSA clients

Comments

0 total · 0 threads
Be the first to leave a comment.