Sharing ways to install and uninstall software under Ubuntu

  • 2020-05-27 08:02:07
  • OfStack


In ubuntu, there are three ways I know how to install an application: apt-get and dpkg install deb.

1. Installation through deb package:

Install.deb package:


sudo dpkg -i package_file.deb

Uninstall.deb package:


sudo dpkg -r package_name

2. Installation by apt-get:

The installation


sudo apt-get install package_name

The installation


sudo apt-get remove package_name

sudo dpkg -p package_name Uninstall the package and its configuration files, but cannot resolve dependencies!

sudo aptitude purge pkgname Uninstall software packages and their configuration files and dependency packages!

Clears all remaining configuration files for deleted packages

 dpkg -l |grep ^rc|awk '{print $2}' |sudo xargs dpkg -P

If the following error is reported, there are no remaining configuration files on your system, so don't worry


 dpkg: --purge needs at least one package name argument


Related articles: