How To Remove/Uninstall Software Packages From Debian, Ubuntu, Linux Mint?

How To Remove/Uninstall Software Packages From Debian, Ubuntu, Linux Mint?

   

This post was last updated on August 1st, 2020 at 12:21 pm

Different Linux distribution comes with different tools to manage software packages on it. Debian and its derivative use the apt package manager to install and remove packages from a system.

You can use aptitude or synaptic to manage software packages from GUI. Linux distributions such as Ubuntu provide software center from where you can install or remove a software package graphically.

In this article, we will discuss removing an installed package from the command line in Debian, Ubuntu, Linux Mint, etc.

Advanced Packaging Tool (apt)

The apt provides a command-line interface to interact with core libraries of OS for the installation, up-gradation, and removal of a package. It can be considered as the front end to dpkg which is used in Debian, Ubuntu, and its derived Linux distributions.

dpkg (Debian package)

The dpkg is also used to install, remove, and perform such other operations on the .deb file. It is a low-level tool it works with downloaded files unlike apt which can fetch the packages from a remote location and can resolve dependencies.

How to remove software packages from Debian, Ubuntu, and Linux Mint?

To remove a package in a debian based system you could use the following command –

sudo apt-get remove package_name

For example –

sudo apt-get remove vlc

You can remove a package using dpkg also by using –

sudo dpkg -r package_name

For example –

sudo dpkg -r vlc

Remove software packages by using the apt-get purge command

The apt-get purge command will remove the software and clean modified user configuration files that were left after the removal of software. This command will also remove the dependencies of a package.

Now use the following command to remove a software package –

sudo apt-get purge package_name

For example –

sudo apt-get purge vlc

The above command will remove vlc as well as its dependencies.

How to remove dependencies that are no longer needed?

The apt autoremove command removes packages that were automatically installed because some other package required them, but when the package was removed, they are no longer needed.

Execute the following command to remove the packages that are no longer needed –

sudo apt-get autoremove

The packages that will be removed here can also be known as unused dependencies.

Conclusion

Now by reading this article you are able to remove a software package from a Debian based distribution. If you have any thoughts on the topic you can share it with us in the comments below.

Previous How To Setup NFS In Ubuntu 20.04 LTS?
Next How To Remove/Uninstall Software packages from CentOS, RHEL, Fedora?

About author

You might also like

Linux Topics 0 Comments

How To Change The Execution Priority Of A Process In Linux?

This post was last updated on August 1st, 2020 at 12:24 pmIn Linux, a process is an instance of a program that is running on a computer. When a program

How To 0 Comments

How To Install And Configure Gnome Desktop in FreeBSD?

This post was last updated on August 1st, 2020 at 12:05 pmFreeBSD is a free and open-source Unix-like operating system descended from the Berkeley Software Distribution. It is used to power

How To 0 Comments

How To Execute A Command With Superuser Privilege In FreeBSD?

This post was last updated on August 1st, 2020 at 10:28 amA superuser or root user is a most privileged user account in FreeBSD. It has access to all the

0 Comments

No Comments Yet!

You can be first to comment this post!

Leave a Reply