Linux is complicated for different reasons you may find various differences when you move from one distribution to another. RPM and Deb are two different file formats used in Linux.
RPM is the installation package format for Red Hat Enterprise Linux(RHEL) and the distributions that are based on it which includes CentOS, SUSE Linux, Rocky Linux, etc. Debian-based distributions such as Ubuntu, Linux Mint, and Kali Linux use the Deb package format for the installation of software packages.
You can not install an RPM package on Debian-based distributions or a Deb package on RPM-based distributions because doing so may lead to dependency conflicts. However, you can install a Deb package on an RPM-based distribution by converting it into an RPM package format.
In this article, I will discuss how to convert Deb to RPM package format by using Alien software.
To follow this guide you should have the following –
- A system running an RPM-based Linux distribution (Here I will use Fedora)
- Access to a user account with sudo priviledges
Installing Alien on Fedora
Alien is a tool that translates a Deb package into an RPM package and vice versa. It is available in the default repository of Fedora.
Before installing a package make sure the dnf package repository is updated –
sudo dnf update
Next, use the given command to install Alien on your Fedora system –
sudo dnf install alien
Press y and then enter when it asks for your confirmation.
You can verify the installation by using –
Converting Deb to RPM package format
Once the Deb package is downloaded, use the following command to convert it into an RPM package format –
sudo alien <package_name>.deb
For example –
sudo alien --to-rpm teamviewer_amd64.deb
You will see a message that the RPM file is generated successfully as you can see in the above image.
Now you can install this generated RPM file by using the rpm command in your terminal –
sudo rpm -i teamviewer-15.28.8-2.x86_64.rpm
Note:- Always prefer to use the rpm package which is provided officially instead of converted package for the installation of an application on your system
We hope you have successfully installed Alien and are able to convert a package from Deb to RPM package format. Now if you have a query or feedback then write us in the comments below.