AlmaLinux

Install FFmpeg on Rocky Linux 9|AlmaLinux 9|Oracle Linux 9

FFmpeg is a free and open-source project that consists of programs and libraries capable of transcoding audio, video, and other multimedia files/streams. The core of this tool consists of the command line FFmpeg which processes the audio and video files. The main task of FFmpeg is format transcoding and basic editing that includes trimming, video scaling e.t.c. The libraries included in this project are:

Original content from computingforgeeks.com - post 67690
  • Libavcodec – an audio/video codec library
  • Libavformat (Lavf) – an audio/video container mux
  • Libavfilter – used for enhancing and editing filters through a Gstreamer-like filter graph.
  • Libavutil – utility library to aid portable multimedia programming
  • Libswscale – performs highly optimized image scaling and colorspace and pixel format conversion operations.
  • Libswresample – performs highly optimized audio resampling, rematrixing, and sample format conversion operations.
  • Libavdevice – provides a generic framework for grabbing from and rendering to many common multimedia input/output devices

The amazing features associated with FFmpeg are:

  • Supports several protocols such as HTTP/HTTPS, TCP, TLS, UDP, FTP, SFTP, HLS, UDP-Lite e.t.c
  • Supports filters that include; Resampling, Pass/Stop filters, Equalizer, Dynamics, Distortion, Filtering e.t.c
  • Supports media and interfaces such as compact discs, Advanced Linux Sound Architecture (ALSA), OpenAL (input only), Windows DirectShow e.t.c
  • SUpports several common and uncommon image, audio, and video formats.

This guide offers an illustration of how to install and use FFmpeg on Rocky Linux 9|AlmaLinux 9|Oracle Linux 9. Everything here was re-run on Rocky Linux 9 in September 2026, including the two dependency errors that trip most people up and the one-line fix for each. Before we dive into the crux of this matter, you need to ensure that all the available packages are updated to their latest available versions.

sudo dnf -y update

Step 1 – Add the RPM Fusion Repository

The FFmpeg packages are not provided in the default Rocky Linux 9|AlmaLinux 9|Oracle Linux 9 repositories. To be able to install FFmpeg, we need to add the RPM Fusion repository to the system.

Begin by enabling the EPEL repository:

sudo dnf -y install https://download.fedoraproject.org/pub/epel/epel-release-latest-9.noarch.rpm
sudo dnf install yum-utils -y
sudo /usr/bin/crb enable

## On Oracle Linux 9
sudo dnf config-manager --enable ol9_codeready_builder

Now proceed and add the RPM Fusion repository:

sudo dnf install --nogpgcheck https://mirrors.rpmfusion.org/free/el/rpmfusion-free-release-9.noarch.rpm -y
sudo dnf install --nogpgcheck https://mirrors.rpmfusion.org/nonfree/el/rpmfusion-nonfree-release-9.noarch.rpm -y

Confirm every repository is actually enabled before installing anything. A missing CRB or RPM Fusion line here is the most common reason the install later refuses to resolve dependencies:

dnf repolist enabled | grep -iE 'crb|epel|rpmfusion'

On Rocky Linux 9 the output should list five repositories:

crb                       Rocky Linux 9 - CRB
epel                      Extra Packages for Enterprise Linux 9 - x86_64
epel-cisco-openh264       Extra Packages for Enterprise Linux 9 openh264 (From Cisco) - x86_64
rpmfusion-free-updates    RPM Fusion for EL 9 - Free - Updates
rpmfusion-nonfree-updates RPM Fusion for EL 9 - Nonfree - Updates

Step 2 – Install FFmpeg on Rocky Linux 9|AlmaLinux 9|Oracle Linux 9

Once the RPM Fusion repository has been added, we can easily install FFmpeg with the command:

sudo dnf install ffmpeg ffmpeg-devel
When dnf cannot resolve the dependencies

If the command ends in a wall of requires or conflicts lines instead of a transaction, it is one of two causes. Read the first line of the error to tell them apart.

Nothing provides ladspa needed by rubberband. The CRB repository is not enabled:

Error: 
 Problem 1: package ffmpeg-5.1.10-1.el9.x86_64 from rpmfusion-free-updates requires libavfilter.so.8()(64bit), but none of the providers can be installed
  - package libavfilter-free-5.1.9-1.el9.x86_64 from epel requires librubberband.so.2()(64bit), but none of the providers can be installed
  - package ffmpeg-libs-5.1.10-1.el9.x86_64 from rpmfusion-free-updates requires librubberband.so.2()(64bit), but none of the providers can be installed
  - conflicting requests
  - nothing provides ladspa needed by rubberband-3.1.3-2.el9.x86_64 from epel

FFmpeg pulls in a chain of audio filter libraries whose own build dependencies live only in CodeReady Builder, so dnf walks the chain and dead ends. Enable the repository and run the install again:

sudo /usr/bin/crb enable
sudo dnf install ffmpeg ffmpeg-devel

Conflicts with ffmpeg-free. EPEL ships a stripped build called ffmpeg-free that drops the patent encumbered encoders, and something on the host has already pulled it in:

Error: 
 Problem 1: problem with installed package ffmpeg-free-5.1.9-1.el9.x86_64
  - package ffmpeg-5.1.10-1.el9.x86_64 from rpmfusion-free-updates conflicts with ffmpeg-free provided by ffmpeg-free-5.1.9-1.el9.x86_64 from @System
  - conflicting requests
 Problem 2: problem with installed package libswscale-free-5.1.9-1.el9.x86_64
  - package ffmpeg-libs-5.1.10-1.el9.x86_64 from rpmfusion-free-updates conflicts with libswscale-free provided by libswscale-free-5.1.9-1.el9.x86_64 from @System
  - package ffmpeg-devel-5.1.10-1.el9.x86_64 from rpmfusion-free-updates requires ffmpeg-libs(x86-64) = 5.1.10-1.el9, but none of the providers can be installed
  - conflicting requests

The two builds cannot coexist because they own the same libraries. Let dnf replace the EPEL set with the RPM Fusion one:

sudo dnf install ffmpeg ffmpeg-devel --allowerasing

Drop the -y the first time and read the Removing dependent packages section of the transaction so you know what leaves with it. On a host that only had the EPEL build it is the nine matching library packages and nothing else:

Removing dependent packages:
 ffmpeg-free          x86_64  5.1.9-1.el9                    @epel                   2.2 M
 libavcodec-free      x86_64  5.1.9-1.el9                    @epel                   9.6 M
 libavdevice-free     x86_64  5.1.9-1.el9                    @epel                   227 k
 libavfilter-free     x86_64  5.1.9-1.el9                    @epel                   4.3 M
 libavformat-free     x86_64  5.1.9-1.el9                    @epel                   2.6 M
 libavutil-free       x86_64  5.1.9-1.el9                    @epel                   835 k
 libpostproc-free     x86_64  5.1.9-1.el9                    @epel                   122 k
 libswresample-free   x86_64  5.1.9-1.el9                    @epel                   151 k
 libswscale-free      x86_64  5.1.9-1.el9                    @epel                   623 k

Once the installation is complete, check the installed version as below:

$ ffmpeg -version
ffmpeg version 5.1.10 Copyright (c) 2000-2026 the FFmpeg developers
built with gcc 11 (GCC)
....

Check more information about the package

$ rpm -qi ffmpeg
Name        : ffmpeg
Version     : 5.1.10
Release     : 1.el9
Architecture: x86_64
Install Date: Mon 07 Sep 2026 11:31:09 AM UTC
Group       : Unspecified
Size        : 2295184
License     : GPLv3+
Signature   : RSA/SHA256, Tue 30 Jun 2026 06:14:57 AM UTC, Key ID 7403ea33296458f3
Source RPM  : ffmpeg-5.1.10-1.el9.src.rpm
Build Date  : Mon 29 Jun 2026 08:06:17 AM UTC
Build Host  : buildvm-07.virt.rpmfusion.net
Packager    : RPM Fusion
Vendor      : RPM Fusion
URL         : https://ffmpeg.org/
Bug URL     : https://bugz.rpmfusion.org/ffmpeg
Summary     : Digital VCR and streaming server
Description :
FFmpeg is a complete and free Internet live audio and video
broadcasting solution for Linux/Unix. It also includes a digital
VCR. It can encode in real time in many formats including MPEG1 audio
and video, MPEG4, h263, ac3, asf, avi, real, mjpeg, and flash.

Step 3 – Use FFmpeg on Rocky Linux 9|AlmaLinux 9|Oracle Linux 9

FFmpeg can be used to perform a variety of functions depending on the individual’s needs. For this guide, we will focus on the main use which is transcoding.

Basic conversion

During conversion, you need to specify the input and output files. The input formats are detected automatically and the output is guessed depending on the provided filename extension.

  • Convert video files from mp4 to WebM:

For example, converting a video file to WebM format, use the below syntax.

ffmpeg -i input.mp4 output.webm

Using the command will be:

ffmpeg -i sample-mp4-file.mp4 output.webm

After the command, I will have the output.webm in my working directory.

  • Convert audio files from mp3 to Ogg

Audio files can be converted to the Ogg format using the syntax.

ffmpeg -i input.mp3 output.ogg

Using a codec

You can transcode a file by specifying the codec to be used. Normally, the -cflag is used to specify the codec.

For example, the above commands can be used with the codec as below:

  • Convert video files from mp4 to WebM using the libvpx video codec and libvorbis audio codec as below:
ffmpeg -i input.mp4 -c:v libvpx -c:a libvorbis output.webm
  • Convert audio files from mp3 to Ogg encoded with libopus codec.
ffmpeg -i input.mp3 -c:a libopus output.ogg
  • Extract audio from a Video file
ffmpeg -i video.mp4 -c:a libmp3lame -q:a 0 -map a output_file.mp3

Replace video.mp4 with the name input video file and output_file.mp3 with the audio file name. The – c:a flag is used to specify the codec for the audio and -q:a defines a variable bitrate for the audio file.

Check more command-line options for FFmpeg using the command:

ffmpeg --help

Closing Thoughts.

That marks the end of this brief guide on how to install and use FFmpeg on Rocky Linux 9|AlmaLinux 9|Oracle Linux 9. I hope this was significant and very helpful to you.

Related posts:

Keep reading

Patch PHP2Shell on RHEL, Rocky Linux and AlmaLinux 10 / 9 / 8 AlmaLinux Patch PHP2Shell on RHEL, Rocky Linux and AlmaLinux 10 / 9 / 8 Customize KDE Plasma Desktop with Themes|Modules|Extensions AlmaLinux Customize KDE Plasma Desktop with Themes|Modules|Extensions Linux Terminal Shortcuts Cheat Sheet (Bash and zsh) Cheat Sheets Linux Terminal Shortcuts Cheat Sheet (Bash and zsh) Install Zabbix 8.0 LTS on Rocky Linux 10 / AlmaLinux 10 AlmaLinux Install Zabbix 8.0 LTS on Rocky Linux 10 / AlmaLinux 10 Install K3s on Rocky Linux 10 (Kubernetes Cluster Setup) Containers Install K3s on Rocky Linux 10 (Kubernetes Cluster Setup) LVM Snapshots for Consistent Server Backups on Linux Backup LVM Snapshots for Consistent Server Backups on Linux

2 thoughts on “Install FFmpeg on Rocky Linux 9|AlmaLinux 9|Oracle Linux 9”

    • Hallo Michael, thanks for flagging this. I re-ran the guide on Rocky Linux 9 today and there are two separate ways it can fail to resolve dependencies. The first line of the dnf error tells you which one you hit.

      1) “nothing provides ladspa needed by rubberband” means the CRB repository is not enabled. FFmpeg pulls in a chain of audio filter libraries whose own dependencies live only in CodeReady Builder, so dnf walks the chain and dead ends. On Rocky Linux and AlmaLinux run “sudo /usr/bin/crb enable”, then repeat the install. On Oracle Linux run “sudo dnf config-manager –enable ol9_codeready_builder”.

      2) “conflicts with ffmpeg-free” means EPEL’s stripped FFmpeg build is already installed on the host and owns the same libraries as the RPM Fusion one. Let dnf replace it: “sudo dnf install ffmpeg ffmpeg-devel –allowerasing”. Drop the -y the first time and read the “Removing dependent packages” list so you can see what goes with it.

      Either way, check the repositories are really enabled before installing:

      dnf repolist enabled | grep -iE ‘crb|epel|rpmfusion’

      You should get crb, epel, epel-cisco-openh264, rpmfusion-free-updates and rpmfusion-nonfree-updates. A missing line there is almost always the actual cause.

      I have added both errors and their fixes to the guide in Step 1 and Step 2. If neither matches what you saw, paste the first few lines of your error here and I will dig into it.

      Reply

Leave a Comment

Press ESC to close