How To Uninstall A Program By Terminal On Ubuntu

December 10, 2013 | By in OPENSOURCE, UBUNTU HOWTO
| Reply More

Have you ever used your terminal to uninstall your programs in your ubuntu machine? It is not that hard! Terminal is real power and you need to learn it. Practise, practise and practise and one day you will feel the joy of using the terminal for almost everything. Now let me introduce you guys to my simple problem.

I have installed teamviewer 8 from a deb package and i am not using it anymore, so i decided to uninstall this software, but i want to do it from terminal since i love it and makes me understand how things work from a low level. But, the question is, how?  Do you know what a deb package is? Since is very important to know what a deb package is i am explaining it to you in two or three short sentences.

A deb package is an archive which contains two tar  archives . These archives may be compressed with gzip (zlib), Bzip2, lzma, or xz programs and the deb package is handled by dpkg or other programs such as apt/aptitude, the Ubuntu Software Center, Synaptic or Gdebi. So, when i installed teamviwer i installed the deb package of it.

"Debian packages can be converted into other packages and vice versa using alien, and created from source code using CheckInstall or Debian Package Maker." (Wikipedia)

I thnink you guys understand now that to remove teamviwer 8 from my ubuntu machine i have to remove the the package with its configuration files. What if you don not remember the exact name of the package you want to remove? Don't worry! The Tab will help you to autocomplete the name of the package.

Find the package name with  dpkg

I use dpkg -l | grep -i teamviewer command to find the package name of teamviewer. You can see it on Figures.

Figure 1

Remove the package from terminal

Use apt-get purge package_name to remove the package with its configuration files.

Figure 2

Figure 3

Figure 4

Figure 5


I  showed you how to use apt-get purge package_name for removing my teamviwer package, but you can use it to remove any package you like.


Share This :

Free Linux Ebook to Download

Leave a Reply

Commenting Policy:
Promotion of your products ? Comment gets deleted.
All comments are subject to moderation.