Ubuntu 19.10 to use LZ4 compression to boot even faster

The Ubuntu kernel team concluded that LZ4 was the best way to go as it was much faster than the method they currently use in their kernels, GZIP. Read on for details.

Canonical’s Ubuntu 19.10 “Eoan Ermine” will boot even faster than its predecessor, Ubuntu 19.04 “Disco Dingo” according to Ubuntu’s kernel team.

After extensive testing on a variety of compression options on the Ubuntu installation image, Canonical engineers determined that the LZ4 decompression method provided a most appreciable gain in speed.

Ubuntu 19.10
Ubuntu 19.10

The purpose of the kernel team’s testing was to find the most effective compromise between best compression (i.e., small file sizes) and decompression (i.e., speedy unpack times).

Ubuntu’s early boot requires loading and decompressing the kernel and initramfs from the boot storage device. A variety of factors determine this speed, including memory/cache speed for decompression and the compression type, the CPU, and speed of loading an image from the boot device.

Ubuntu 19.10 Developmental Build
Ubuntu 19.10 Developmental Build

The Canonical engineers conducted multiple experiments benchmarking several x86 configurations using the x86 TSC (Time Stamp Counter) to measure kernel load and decompression time.  The team tested six different compression types: BZIP2, GZIP, LZ4, LZMA, LZMO, and XZ.

The Ubuntu kernel team concluded that LZ4 was the best way to go as it was much faster than the method they currently use in their kernels, GZIP.

However, the compressed LZ4 kernel was ~25% larger than was GZIP.  This was of no considerable consequence since the longer LZ4 kernel load time was overcome by far faster decompression time.  This was true even with a slow CPU and slow spinny media.

The faster the media became, the clear compression choice was LZ4 decompressing as the load time difference between GZIP LZ4 and LZO diminished.

Kernel compression shaves but fractions (~0.29 seconds on the slow x220 and ~0.05 seconds on faster servers) of a second in terms of total boot time.

Although not huge wins, the sin is but a simple config change. Canonical’s Colin King simplified the explanation on his blog:

Even with slow-spinning media and a slow CPU, the longer load time of the LZ4 kernel is overcome by faster decompression time.

According to the official release schedule on the Ubuntu wiki, Canonical’s Ubuntu 19.10 “Eoan Ermine” release schedule is:

  • Beta Release: September 26, 2019
  • Final Release: October 17, 2019
Travis Rose
Hi, I'm M Travis Rose, a contributor to FOSS Linux. I have over thirty years of experience in the IT arena, at least fifteen of which has been working with Linux. I enjoy converting existing Windows users to the wonderful world of Linux. I guess you could call me a Linux-evangelist. Long live Linux!

LEAVE A REPLY

Please enter your comment!
Please enter your name here

STAY CONNECTED

24,353FansLike
189FollowersFollow

LATEST ARTICLES

How to create a bootable CentOS Live USB drive on Windows

create centOS Live USB drive
CentOS ISO downloads are available in two different variations - Minimal ISO and DVD ISO. So what are these? In this guide, you will know how to create a CentOS Live USB drive that can also be used to install CentOS.

RECENT COMMENTS

clean virus ubuntu live CD
In this tutorial, we are going to show you how to clean your Windows machine from infected viruses using an Ubuntu live USB or CD and the ClamAV antivirus. The ClamAV is a free, open-source antivirus that can be used on Ubuntu.
terminate frozen app
For dealing with a frozen app or desktop, you can't use the CTRL+ALT+DEL in Linux system. Instead, there are powerful alternatives that come in handy in frustrating situations. We pick the best methods available for you.
Ubuntu 19.10 beta overview
It may be early, but I've been looking forward to the release of Ubuntu 19.10 for some time now. As an impatient person, and promised readers in the FOSSLinux article announcing the release of Eoan Ermine that we would provide you a review of Ubuntu 19.10 Eoan Ermine - Beta.  So, here it goes.