Skip to content

Get h264 playback on immuteable Fedora

📅 Created: Apr 18, 2025

The Problem ​

On immuteable Fedora distributions, some websites have issues playing back media and the system itself cannot open most MP4 files with built in player, the reason for this it that it lacks the software to read the old but still very common AVC codec, better known as h264.

But why? ​

Fedora ships with the noopenh264 package, which is a placeholder that can be linked against and essentially fakes openh264 while being a dummy that cannot do anything. This is done because Fedora cannot ship regular openh264 with it's images due to licensing. Cisco although already owns a license and makes openh264 available to distros like Fedora in order to support the WebRTC standard, but this means the distros have to download openh264 from Cisco's repo when they can, which apparently happens during the first update of the system.

I am not too familiar with the usual procedue of how this works or why it has to be this way, but on the immuteable versions of Fedora like Silverblue or Kinoite, which utilize a read-only root filesystem with rpm-ostree, instead of a regular muteable system managed by rpm/dnf, this replacing does not happen and apparently no way of fixing this automatically has been found yet, but we can do this manually:

Installing openh264 ​

In order to fix h264 playback, simply tell rpm-ostree to replace the placehodler with actual package like so:

bash
$ rpm-ostree override remove noopenh264 --install openh264 --install mozilla-openh264

See https://github.com/fedora-silverblue/issue-tracker/issues/536#issuecomment-1974780009 for more details.