How to install or uninstall .Deb files packages in ubuntu

Just like we have software packages with .exe file extension on Windows; the Debian or Ubuntu or their based Linux operating systems used the .Deb packages or extensions. Every Debian based Linux operating system use Debian based packages (.DEB) to install or uninstall the software. You can install on uninstall Deb extension files or packages using the command line tool or graphical user interface on Ubuntu.

To install .DEB file of some software, you can download that from their website or directly using the Ubuntu repository.

However, there are lots of companies those software are not listed in the Ubuntu official repository in such case either you need to download .DEB or Debian files/packages of their software to install them manually on Linux.

For example TeamViewer, Google Chrome, and more…

So, how to install these .DEB packages manually on Debian or Ubuntu based systems. In this tutorial, we are going to answer this question. Forgiving you a complete idea, we will install .Deb package of TeamViewer and then we uninstall the same using command line, manually.

Install .deb Packages or files

To install any Debian file with .DEB extension manually you first need to download that and then use it with the below command:

sudo dpkg -i <packagename>

For Example, We need to install TeamViewer on Ubuntu or Debian then first we go to its website and download the .DEB package of Teamviewer 32 bit or 64 bit.

After downloading, open the Command Terminal and Switch the directory to Downloads and then type the above command with the file name:

sudo dpkg -i teamviewer_14.1.3399_amd64.deb

You can also install .Deb files or packages without command line interface

Just open the folder where .DEB file resides and double-clicks on it. As soon as you double-click the Ubuntu Software package management’s graphical user interface will appear with an Install button. Click on that button and Debian package will install.

Note: It is recommended, if you new to Ubuntu Linux then first use the Ubuntu Software GUI to install the Debian package and in case it unable to do that then move to Command Line.

Uninstall .deb Packages or files

Uninstalling the .Deb files are super easy you just need to trigger one command on Command Terminal along with the Debian package name that you want to remove from your system.

The command to uninstall DEB packages is:

sudo dpkg -r <packagename>

-r stands for remove…

The above command is same as the command which we used above to install the packages. The only difference is the expression or option we used. In installation command the dpkg was used with -i which means install and for uninstalling deb packages we used the same command with -r means Remove.

Now to uninstall the above install Teamviewer DEB package, we use the command in the following way.

To Uninstall Debian packages manually using the Graphical user interface you just need to click on the Ubuntu User interface and then click on the Installed Tab after that search the installed Debian package or software you want to remove or uninstall from Ubuntu.

Extract deb file ubuntu

You can even extract the Debian file packages to know what is inside. For that

dpkg-deb -x <filename> ~/<folder>

Filename: The name of .DEB file which you want to extract

Folder: Type some name to the folder where you want to save the extract file. You can give any random name.

About The Author

Rajkumar Maurya is the H2S Media tech expert. He’s always been passionate about technology and has been writing on the subject since 2014. He has extensive knowledge of all kinds of technology, from consumer-tech to enterprise solutions. Follow him on:Twitter | Instagram
You can contact the author at-- raj@how2shout.com