Ubuntu 20.04 vs 22.04: Comparing features and performance

Written by David Worthington on August 2, 2024

Share This Article


Contents


Jump to Tutorial

Ubuntu is a popular Linux distribution that has been adopted by many system administrators, developers, or everyday users who are searching for a robust and open-source operating system. Each version of Ubuntu brings new features, improvements and sometimes there are certain changes in system requirements.

Ubuntu releases a new version every six months; whereas, Long Term Support versions (LTS) are released every two years. The difference is that LTS versions are supported for the next five years, which is more appropriate for production environments. Regular releases receive nine months of active support, but the tradeoff is that they often contain the latest features, beta functionalities, and various updates that aren’t found in LTS releases.

This tutorial will compare features and performance between different versions of Ubuntu, and we will focus on LTS versions that are suitable for production environments.

Comparing Features

Ubuntu 18.04. LTS (Bionic Beaver)

Release Date: April 2018

Support End Date: April 2023

Kernel Version: 4.15

Key Features:

  1. GNOME 3.28: Here it became the default desktop environment, replacing Unity.
  2. Minimal Installation Option: Install a basic version of Ubuntu with essential utilities only.
  3. Improved Boot Speed: Optimizations for faster boot times.
  4. Updated Software Packages: Includes Python 3.6, LibreOffice 6.0, and others

Note that this version has reached End of Life (EOL) and Ubuntu recommends upgrading it to newer and actively supported versions.

Ubuntu 20.04 LTS (Focal Fossa)

Release date: April 2020

Support End Date April 2025

Kernel Version: 5.4

Key Features:

  1. Gnome 3.36: Enhanced performance and various new features in the desktop environment.
  2. It carries enhanced ZFS support with automated snapshots.
  3. WireGuard VPN: Support for WireGuard VPN in the kernel.
  4. Updated Software Packages: Includes Python 3.6, Libre Office 6.4, GCC 9.3, PHP 7.4 and others.

Ubuntu 22.04 LTS (Jammy Jellyfish)

Release Date: April 2022

Support End Date: April 2027

Kernel Version: 5.15

Key Features:

  1. GNOME 40: Major update to the GNOME desktop environment that included significant improvements in usability and performance.
  2. Improved Hardware Support: Enhanced support for modern hardware components.
  3. Enhanced Security Features: There were various security enhancements, including memory management and protection as well as mitigations against Spectre and Meltdown vulnerabilities.
  4. Updated Software Packages: Includes Python 3.10, LibreOffice 7.4, PHP 8.1, GCC 11.2 and others.

Ubuntu 24.04. LTS (Noble Numbat)

Release Date: April 25, 2024

Support End Date: 

  • April 2029 (Standard support)
  • April 2036 (Extended support with Ubuntu Pro)

Kernel Version: 6.8

Key Features: 

  1. GNOME 46: This version brings enhanced performance and usability improvements as well as various upgrades to the Nautilus file manager.
  2. Confidential Computing: Extensive support for confidential virtual machines that are available on public clouds like AWS, Google Cloud, and Microsoft Azure. 
  3. Improved Security and Management Tools: It includes Active Directory Group Policy client for enterprise environments, 12 years of support with the new Ubuntu Pro add-on as well as real-time kernel support, available through Ubuntu Pro which enhances performance for real-time applications.
  4. Updated Software Packages: Includes Python 3.12, OpenJDK 21, GCC 14, PHP 8.3, and others.

Practical Examples

There are various ways to set up virtual machines and provision different versions of Ubuntu, ranging from local hypervisors such as VirtualBox and VMWare to containerization tools like Docker and LXD. Additionally, you can provision Ubuntu with major cloud providers such as AWS, Azure, GCP. Cloud hosts offer a streamlined process for creating and managing Ubuntu instances, making it easier to deploy and scale applications. 

Each approach has its advantages and it will depend on the specific requirements of your project. Also, when testing multiple Ubuntu versions, VirtualBox can be the most affordable option.

Step 1: Install and Setup VirtualBox

You can download VirtualBox for your operating system by visiting the link.

Here you can select the installation packages depending on your operating system.

tutorial screenshot

Next, download Ubuntu ISOs for your selected versions from the official Ubuntu releases page.

Now, you can open VirtualBox and select ‘New’ where you can configure your new operating system.

tutorial screenshot

In the prompt, you can add information such as Name, a location where you want to store files needed for the system to run, and the location of the ISO image that you will load for installation purposes.

tutorial screenshot

In the next step, you can configure a username, password, and information such as hostname.

tutorial screenshot

Click Next, and the prompt will ask us about the hardware resources you want to provide to the virtual machine. The minimum requirement for Ubuntu is 1024 MB or 1GB of RAM but it is recommended to use 3GB or more. If you are doing some light testing, 1 vCPU may be enough for some minimal and server installs, but it is recommended that you place at least 2 vCPU cores in your setup.

tutorial screenshot

After clicking ‘Next’, select the amount of storage to give the virtual machine. Ubuntu recommends a minimum storage of 25 GB or more. This examples shows that there’s enough space to install the system and use it properly.

tutorial screenshot

After clicking Next, you can follow through the installation process and choose language and other options based on your preferences.

tutorial screenshot

Finally, create a new VM for each Ubuntu version, allocate resources, and attach the ISO files. You can install Ubuntu on each VM following standard installation procedures. The procedure in older Ubuntu versions is similar as well as the process you need to finish in VirtualBox. By following these steps, you are ready to utilize multiple Ubuntu versions and check their performance and features.

Step 2: Comparing Boot Times

Boot time is crucial for understanding system performance. 

We can use systemd-analyze as a powerful tool included with systemd, which is the initialization system used by modern Linux distributions, including Ubuntu. This tool provides various functionalities to analyze the boot process of your Ubuntu system. 

We can check the overall boot time by running the following command:

systemd-analyze

tutorial screenshot

This command will display the total time for the system to boot, breaking it down into kernel time, userspace time, and time spent when all services required for the graphical user interface have started and the system is ready for user interaction.

We can expand this command with the flag blame in our command.

systemd-analyze blame

This command will list all the services and how long each took to start, which can be very useful when troubleshooting services that are causing delays.

tutorial screenshot

Furthermore, you can use the ‘critical-chain‘ flag which shows services, sockets, mount points and similar, and they are critical for the boot process, where the output shows which units are delaying the boot.

systemd-analyze critical-chain

tutorial screenshot

This is where you can compare boot times among different Ubuntu versions.

Step 3: Application Launch Speed

Testing application launch speed provides insight into real-world performance differences.

Depending on whether you are using a graphical user interface or just the terminal you can use the command time, which measures launch time. 

time sleep 3

tutorial screenshot

Let’s examine the output:

real – 0m3.003s: This indicates that the total wall-clock time from the start to the end of the sleep 3 command was approximately 3.003 seconds.

user – This shows that the CPU spent 0.003 seconds executing user-space processes. For the sleep command, this value is very low because sleep primarily involves waiting and does not perform any significant user-space computations.

sys – 0m0.000s: This indicates that the CPU spent 0.000 seconds on system (kernel) operations on behalf of the process. Again, since sleep does very little besides waiting, it does not require significant system resources.

Repeat this for multiple applications such as LibreOffice Writer, Terminal, and Gedit. You can compare launch times by using different Ubuntu versions and document the differences.

Step 4: System Resource Usage

Between versions, we can also measure the CPU and memory usage on our system. One very convenient way is to use htop which shows information about the system’s uptime, current load, memory usage as well as processes and how much these processes are consuming resources on our system. You run this by simply typing:

htop

tutorial screenshot

Next, measure the disk’s performance which affects the speed of read/write operations and overall system responsiveness.

Use the ‘dd‘ command for the disk write speed test.

sudo dd if=/dev/zero of=/tmp/test1.img bs=1G count=1 oflag=direct

tutorial screenshot

As an output, we can see the speed that is available to us when creating a file filled with zeroes. By writing a large file directly to disk, we can measure the raw write speed of the disk. This is useful for benchmarking between versions and also when comparing different storage devices.

We can also measure read speed using the ‘hdparm’ command.

sudo hdparm -Tt /dev/sda

tutorial screenshot

Then, you can record read/write speeds for each Ubuntu version. 

Through these practical examples, you can gain a comprehensive understanding of the differences in features and performance across different Ubuntu versions. Each newer version of Ubuntu brings additional features as well as optimizations.

David Worthington

I'm the JumpCloud Champion for Product, Security. JumpCloud and Microsoft certified, security analyst, a one-time tech journalist, and former IT director.

Continue Learning with our Newsletter