The RPM packages are built and compiled to use in Fedora and Red Hat-based Linux distributions. The RPM stands for RPM Package Manager. Ubuntu and other Debian distributions use the
.deb package. Sometimes, you would not find your desired Debian package for your Ubuntu Linux, but it might be available in RPM compiled version. In that case, some methods allow you to install RPM packages on your Ubuntu Linux system.
RPM Package on Ubuntu/Debian System
Initially, the RPM package management system was built for Red Hat Linux. Later, it became popular and available for Fedora, SuSE Linux, and other Red Hat-based Linux distributions. As Red Hat and Debian both are different Linux systems and both have their package repository, you should be careful while installing the RPM packages on a Ubuntu Linux to avoid dependency errors. This post will see how you can install RPM packages on your Ubuntu and other Debian Linux distributions.
Step 1: Install Alien Package on Debian System
In Linux, the Alien application is a distribution-package converter for Debian Linux. It can convert RPM packages to Debian format. You can run the following command on your Ubuntu terminal shell with root privileges to install the Alien package on your Debian system.
sudo apt install alien
Step 2: Download an RPM Package
The Alien tool will allow installing the RPM package on your Ubuntu system. But you can’t use the YUM or DNF commands to install RPM packages through the Red Hat’s repository; you need to convert an RPM package to Debian format.
First, you have to download your desired RPM package on your system. Let’s download an RPM package and convert it to RPM. Here, I will download the RPM package of Google Chrome to demonstrate the process. You can pick another RPM packages as well. Click here to download the RPM package of Google Chrome.
Step 3: Install RPM Packages on Debian Linux
There are two methods of installing an RPM package on a Ubuntu system. You can convert an
.rpm package to a
.deb package or you can install an RPM package directly on your Debian system through the Alien tool. Here, we will cover both ways to install an RPM package on a Debian Linux system.
Method 1: Convert and Install an RPM Package on Ubuntu
After installing the Alien tool on your Debian Linux, you may now convert the rpm package you have downloaded earlier. You can follow the process given below to make the package conversion. Run the following command on your terminal shell to convert an RPM package to Debian format. Don’t forget to replace the path and package name with yours.
sudo alien google-chrome-stable_current_x86_64.rpm
While the conversion is successful, you can now run either the
dpkg command or
apt install command on your terminal shell to install the RPM package on your Ubuntu Linux.
Dpkg command to install a package on Ubuntu.
sudo dpkg -i google-chrome-stable_88.0.4324.96-2_amd64.deb
The apt command to install a package on Ubuntu.
sudo apt install ./google-chrome-stable_88.0.4324.96-2_amd64.deb
Method 2: Install an RPM Package Directly on Ubuntu
This is the straightforward process of installing an rpm package on a ubuntu-desktop. First, open the directory where you downloaded the
.rpm package, then run the following Alien command on your terminal shell to install the package directly on your Ubuntu or other Debian-based Linux distributions.
sudo alien -i google-chrome-stable_current_x86_64.rpm
Installing an RPM package on a Debian system is not a complicated task, but you might see some mismatches on the package. Sometimes, the package might not show the default icon, or you could rarely see a minor dependency error on your system. However, I have described what an RPM package is and how you can install it on a Ubuntu desktop and other Debian-based Linux distributions in the entire post.
If you find this post useful and informative, please share it with your friends and the Linux community. We also encourage you to write down your opinions regarding this post in the comment section.