How to Install EPEL and RPM Fusion on AlmaLinux

By Angus Published 3 March 2025 Updated 27 January 2026 2 min read

Installing software beyond the official AlmaLinux repositories often requires third-party sources. This is particularly important when managing your VPS, as you’ll frequently need additional tools and utilities. For example, EPEL is a common prerequisite when you install MERN stack on AlmaLinux.

  • EPEL (Extra Packages for Enterprise Linux)
  • RPM Fusion

Similar to how you might perform an initial server setup for Debian, setting up these repositories is an essential early step for AlmaLinux systems.

Install EPEL

Before installing RPM Fusion, you must install the EPEL repository. This provides the necessary dependencies for many RPM Fusion packages.

To install EPEL, run:

sudo dnf install epel-release

Once installed, update your repositories:

sudo dnf update

Install and verify RPM Fusion GPG keys

Before installing RPM Fusion packages, you need to verify their authenticity by importing and validating the official GPG keys. This ensures the packages you’re installing are legitimate and haven’t been tampered with.

Install distribution GPG keys

sudo dnf install distribution-gpg-keys

If prompted to import a GPG key during installation, verify it against the official RPM Fusion GPG keys page.

Import RPM Fusion keys

Import both the free and non-free GPG keys:

For the free repository:

sudo rpmkeys --import /usr/share/distribution-gpg-keys/rpmfusion/RPM-GPG-KEY-rpmfusion-free-el-$(rpm -E %rhel)

For the non-free repository:

sudo rpmkeys --import /usr/share/distribution-gpg-keys/rpmfusion/RPM-GPG-KEY-rpmfusion-nonfree-el-$(rpm -E %rhel)

Verify Imported Keys

Compare the key fingerprints to the ones listed on the RPM Fusion keys page:

For the free repository:

gpg --show-keys --with-fingerprint /usr/share/distribution-gpg-keys/rpmfusion/RPM-GPG-KEY-rpmfusion-free-el-$(rpm -E %rhel)

For the non-free repository:

gpg --show-keys --with-fingerprint /usr/share/distribution-gpg-keys/rpmfusion/RPM-GPG-KEY-rpmfusion-nonfree-el-$(rpm -E %rhel)

Install RPM Fusion Repositories

Install both the free and non-free repositories with a single command:

sudo dnf --setopt=localpkg_gpgcheck=1 install \
  https://mirrors.rpmfusion.org/free/el/rpmfusion-free-release-$(rpm -E %rhel).noarch.rpm \
  https://mirrors.rpmfusion.org/nonfree/el/rpmfusion-nonfree-release-$(rpm -E %rhel).noarch.rpm

If the installation fails, ensure that the GPG keys imported earlier are correct.

Need more power?

Get scalable resources with our VPS hosting with root access and optional software.

Get VPS Hosting

Starting something new?

Perfect for websites and small businesses unlimited bandwidth with cPanel hosting.

Get cPanel Hosting