How to Install RPM Packages On Ubuntu 22.04

how to install rpm packages on ubuntu 22.04

RPM or Red Hat Package Manager is a free, open-source package management system.

The RPM package management system is written in C and Perl programming languages for Linux operating systems.

It is used in many other distributions, such as Fedora, AlmaLinux, CentOS, and OracleLinux. The Red Hat distributions are Debian and Ubuntu.

Installing RPM packages on Ubuntu 22.04 can be done in two different ways. It is a very easy process that may take a couple of minutes. Let’s get started!

Prerequisites

  • A server with Ubuntu 22.04 as OS
  • User privileges: root or non-root user with sudo privileges

Step 1. Update the System

Before installing the RPM packages, we need to update the system packages to the latest available versions.

sudo apt-get update -y && sudo apt-get upgrade -y

Step 2. Install Alien

Alien is an application used for installing the RPM packages directly or converting the RPM packages into Debian packages. It can install the RPM packages both ways. To install Alien execute the following command:

sudo apt install alien -y

To check the installed Alien version, execute the following command:

alien -V

You should receive the following output:

root@host:~# alien -V
alien version 8.95.5

Step 3. Install RPM packages with the “i” option

This method installs the RPM packages directly, specifying the “i” option in the Alien command. Let’s download the Google Chrome .rpm package and install it with the Alien command.

To download the Chrome .rpm package execute the following command:

wget https://dl.google.com/linux/direct/google-chrome-stable_current_x86_64.rpm

Once downloaded, install it with the command below:

sudo alien -i google-chrome-stable_current_x86_64.rpm

The installation will start and will look like this on the output below:

root@host:~# sudo alien -i google-chrome-stable_current_x86_64.rpm
warning: google-chrome-stable_current_x86_64.rpm: Header V4 RSA/SHA512 Signature, key ID a3b88b8b: NOKEY
warning: google-chrome-stable_current_x86_64.rpm: Header V4 RSA/SHA512 Signature, key ID a3b88b8b: NOKEY
warning: google-chrome-stable_current_x86_64.rpm: Header V4 RSA/SHA512 Signature, key ID a3b88b8b: NOKEY
    .
    .
    .
    .
warning: google-chrome-stable_current_x86_64.rpm: Header V4 RSA/SHA512 Signature, key ID a3b88b8b: NOKEY
        dpkg --no-force-overwrite -i google-chrome-stable_114.0.5735.198-2_amd64.deb
Selecting previously unselected package google-chrome-stable.
(Reading database ... 172411 files and directories currently installed.)
Preparing to unpack google-chrome-stable_114.0.5735.198-2_amd64.deb ...
Unpacking google-chrome-stable (114.0.5735.198-2) ...
Setting up google-chrome-stable (114.0.5735.198-2) ...
Processing triggers for libc-bin (2.35-0ubuntu3.1) ...
Processing triggers for mailcap (3.70+nmu1ubuntu1) ...
Processing triggers for man-db (2.10.2-1) ...

Step 4. Install RPM packages by converting them to Deb packages

The second method is converting the .rpm package to a .deb package. Let’s first download the Firefox rpm package with the following command:

Need a fast and easy fix?
✔ Unlimited Managed Support
✔ Supports Your Software
✔ 2 CPU Cores
✔ 2 GB RAM
✔ 50 GB PCIe4 NVMe Disk
✔ 1854 GeekBench Score
✔ Unmetered Data Transfer
NVME 2 VPS

Now just $43 .99
/mo

GET YOUR VPS
wget https://rpmfind.net/linux/openmandriva/cooker/repository/x86_64/main/release/firefox-114.0.2-3-omv2390.x86_64.rpm

Once the file is downloaded, we need to convert the .rpm package to the .deb package with the command below:

sudo alien firefox-114.0.2-3-omv2390.x86_64.rpm

After this command, the package is converted to a .deb package. To check this, execute the command below:

ls firefox_114.0.2-4_amd64.deb

You should get the following output:

root@host:~# ls firefox_114.0.2-4_amd64.deb
firefox_114.0.2-4_amd64.deb

Now, we can install the Firefox .deb package with the following command:

sudo dpkg -i firefox_114.0.2-4_amd64.deb

That was all. You successfully installed the Alien application to install the RPM packages on Ubuntu 22.04.

If you do not want to do this alone, sign up for one of our NVMe VPS plans and submit a support ticket. Our admins are available 24/7 and will start to work on your request immediately. Always trust our epic support.

If you liked this post on installing RPM packages in different ways on Ubuntu 22.04, please share it with your friends on social networks or simply leave a reply below. Thanks.

Leave a Comment