The Fedora Project is working on a change that could speed up your system’s boot time and save disk space. Starting with Fedora Linux 43, the project plans to compress the initial ramdisk (initrd) using the zstd format by default.
This affects all Fedora editions that build initrd with dracut, the tool responsible for creating the image used during early startup.
If approved, this change will bring a smoother and faster startup experience across desktops, servers, and spins.
Table of Contents
Introduction
The Fedora Project is proposing a significant change to how it compresses a special file used during startup, known as the initial ramdisk (initrd). This change aims to make your system boot faster and use less disk space.
The targeted release for the proposed change to compress the initial ramdisk (initrd) with zstd by default for all Fedora variants when built with dracut is Fedora Linux 43.
What is initrd?
In Linux systems, initrd (initial ramdisk) is a temporary root file system that loads into your computer's memory during the startup process. Think of it as a small, temporary operating system that helps your computer get ready to load the full one.
It's used to prepare things before your computer can access its main file system. This includes loading necessary drivers for things like your hard drive or network, especially if your main file system is on a complex setup like an encrypted partition or a network drive.
The kernel can unpack these initrd or initramfs images if they are compressed with various algorithms, including gzip, bzip2, XZ, and zstd.
dracut is a program used to create these initramfs images on some Linux distributions.
The Proposed Change: Using zstd Compression
The proposal suggests using zstd to compress the initrd by default for all Fedora versions when they are built using dracut.
Currently, most Fedora versions use xz for initrd compression. However, dracut is now set up to use zstd by default if the zstd program is available on your system.
Fedora CoreOS already uses zstd and has a specific compression ratio set for it. This proposed change would make zstd the standard across all Fedora variants.
As of writing this, 95% users are strongly in favor of this change. So it will most likely implemented in Fedora 43. Here is the poll result:
Why is this Change Proposed? (Benefits)
- Smaller
initrd: Usingzstdwill result in a smallerinitrdfile. - Faster Boots: A smaller
initrdalso means faster boot times because it takes less time to decompress and load. - Saves Disk Space: This change is specifically designed to save disk space in the
/bootpartition. This is directly relevant to issues where users might run into a "No space left on device" error when trying to install a new kernel, as the/bootpartition can easily run out of space during upgrades.
Impact on Users
For most users, there should be no noticeable impact other than slightly faster boot times. This is because the Linux kernel has supported zstd decompression for quite some time.
Existing Fedora installations will automatically update to use zstd by default, and no manual action is required from you.
If you prefer to keep using xz for initrd compression, you can configure your dracut settings to do so.
Developers will need to make sure their tools still work with the new compression method.
How to Test the Change
If you're an advanced user and keen to test this out on a package-mode Fedora system (like Fedora Workstation) before it's officially released, you can follow these steps.
Install zstd using command as root user:
dnf install -y zstd
Rebuild your initrd file:
dracut <path to initrd>
or
dracut --regenerate-all
for all kernel versions.
Check if it's zstd compressed:
LANG=C grep -aUPq "\x28\xb5\x2f\xfd" <path to initrd> && echo "using zstd" || echo "not using zstd"
Reboot your system to experience the change.
For other system types, you might need to wait for the change to land in development versions or build your own images.
A More Efficient Fedora is Coming
This proposed shift to zstd compression for the initrd is a smart move for Fedora.
By embracing a modern, efficient compression algorithm, Fedora is set to deliver faster boot times and help users avoid frustrating /boot partition full errors, ultimately enhancing the overall user experience.
We look forward to Fedora Linux 43 and these welcome improvements!
Related Read: Fedora Linux 43 to Drop MBR Support for UEFI x86 Installs

