Enhancing CPU performance and conserving energy using IntelⓇ QuickAssist Technology (IntelⓇ QAT) on Ubuntu 24.04

Share it

When it comes to enterprise software and services, the deployment of load balancers plays a crucial role in maintaining reliability, availability, and speed by evenly distributing traffic among various servers. Many load balancers offer functionalities to handle the necessary cryptographic handshakes for establishing secure connections with TLS, a crucial protocol for securing HTTPS traffic. These TLS operations heavily rely on compute-intensive algorithms that can put a strain on the CPU, especially under high request loads. In this article, we explore the potential to significantly lessen CPU load on HAProxy, a widely used open source load balancer, by transferring these tasks to IntelⓇ QuickAssist Technology (IntelⓇ QAT) on Ubuntu 24.04 LTS. The advantages of this approach include:

  • Dealing with higher traffic volumes
  • Saving energy
  • Releasing the CPU for other operations

Support for IntelⓇ QuickAssist Technology (IntelⓇ QAT) on Ubuntu 24.04 LTS

The IntelⓇ QAT accelerator is specifically crafted for offloading particular operations from the CPU, notably cryptographic and data compression tasks. Not only does IntelⓇ QAT enhance raw performance as expected from an accelerator, but it also aids in reducing CPU utilization by transferring encryption and compression responsibilities to an IntelⓇ QAT device, thereby freeing the CPU for diverse assignments. This article focuses on decreasing CPU load, resulting in decreased power consumption and overall savings as fewer cores might be needed to handle a scaled-up workload.

Ubuntu 24.04 LTS signals the initial Ubuntu release that officially integrates IntelⓇ QAT support, accessible through packages within the Ubuntu repository. The IntelⓇ QAT software suite comprises kernel space and user space components. The kernel space element is delivered as a kernel driver included in the 6.8 stable kernel. Meanwhile, the user space segment is provided via a set of packages in the Ubuntu repository installable using the apt command. Below is a summary of the pertinent packages essential for the scenario elaborated in this article:

Miraculously, the first four packages serve as dependencies for the final package: IntelⓇ QuickAssist Technology OpenSSL* Engine. Consequently, all these components can be installed by executing the following command:

sudo apt -y install qatengine

Diminishing CPU Usage of the HAProxy Load Balancer

To exhibit the potential of IntelⓇ QAT on Ubuntu 24.04 LTS, this section illustrates the advantages of blending it with HAProxy. HAProxy is structured to distribute network traffic across a pool of backend servers optimally. One of HAProxy’s many features is its ability to manage TLS handshakes for a group of web servers that receive requests via HTTPS. TLS handshakes encompass a series of cryptographic processes (e.g., key exchanges) that can be outsourced to IntelⓇ QAT, enabling the CPU to handle other responsibilities.

To emphasize the efficiency gains, we conducted benchmarks on HAProxy running on 4th Gen IntelⓇ XeonⓇ Platinum 8488C processors equipped with in-built IntelⓇ QAT devices on Ubuntu 24.04 LTS. All tools and libraries (including those mentioned in the earlier table) were installed via apt from the Ubuntu repository, except for HAProxy itself, which was compiled with SSL Engine support activated from the recent 3.0 version. To enable IntelⓇ QAT support during runtime, HAProxy was set up with ssl-engine qatengine algo ALL and ssl-mode-async activated.

HAProxy benchmarks

Graph 1. The HAProxy CPU usage and TLS Handshake performance (measured in connections per second) under various HTTPS client loads. Higher x-axis values signify increased CPU stress, while higher y-axis values indicate superior performance.

The outcome of measuring CPU usage and connections per second under different loads from ApacheBench clients on the HAProxy load balancer showcases the advantages of IntelⓇ QAT offloading compared to native OpenSSL (version 3.0.13). IntelⓇ QAT technology includes both a hardware aspect (QATHW) and a software element (QATSW) that utilizes deeply optimized cryptographic libraries designed to run efficiently on modern Intel CPUs through multi-buffer processing and the IntelⓇ AVX-512 instruction set. As depicted in Graph 1, significant benefits emerge from offloading to QATSW, outperforming native OpenSSL by a notable margin. In essence, QATSW achieves equivalent performance to native OpenSSL but with lower CPU usage, translating to diminished energy consumption and operational expenses.

Enhanced CPU efficiency (i.e., reduced CPU utilization) and heightened performance are realized when a single IntelⓇ QAT device is configured for cryptographic tasks. The IntelⓇ QAT OpenSSL* Engine package supports QATHW and QATSW coexistence (known as QATHW+SW) by distributing work effectively between the two pathways; this behavior is activated in the qatengine apt package on Ubuntu 24.04 LTS. For comprehensive insights on configuring and fine-tuning IntelⓇ QAT devices based on specific needs, consult the IntelⓇ QAT Configuration and Tuning Guide. While this article spotlights relative performance enhancements, it’s plausible that further configuration and tuning could yield even greater raw performance.


Through this discussion, we’ve highlighted how IntelⓇ QAT can be harnessed in Ubuntu 24.04 LTS to offload demanding workloads, bolstering CPU efficiency and driving financial savings. The showcased data underscores that IntelⓇ QAT can augment an application’s performance significantly. While our benchmarks primarily focused on HAProxy, a myriad of other workloads could also reap comparable benefits, provided they heavily rely on cryptographic or compression tasks. The straightforward accessibility and installation of IntelⓇ QAT packages and libraries on Ubuntu 24.04 LTS position it as a desirable platform for integrating, testing, and deploying applications with IntelⓇ QAT support. If you possess an IntelⓇ QAT device and wish to test it out, seize the opportunity to download Ubuntu 24.04 LTS at the Ubuntu Server Download page.

Source: Ubuntu Blog

🤞 Don’t miss these tips!

🤞 Don’t miss these tips!

Solverwp- WordPress Theme and Plugin