Introduction

This section covers Debian Package Managers:

  • How to find software ?
  • How to install software ?
  • How to remove software ?

Debian Package Manager - APT

Another popular package format is the Debian package format. Here is a list of distributions that are based on the DEB package format.

  • Debian
  • Linux Mint
  • Ubuntu

The Debian base distributions use a package manager called Advanced Packaging Tool (APT). APT is comprised of a few small utilities with the two most commonly used are apt-cache and apt-get .

To search for packages, use apt-cache search string. To install the package, use apt-get install [-y] package_name. You can specify the -y to automatically answer yes to any apt-get's questions. To remove a package, use apt-get remove package_name. However, any configuration files or configuration changes will stay on your system when you use apt-get remove. If you would like to get rid of the configuration file in addition to the package, you can use the apt-get purge package_name. To show information about a particular package, use apt-cache show package_name.

Command Meaning
apt-cache search string Search for packages with string
apt-get install [-y] package_name Install package.
apt-get remove package_name To remove a package, but leave configuration.
apt-get purge package_name To remove a package and also delete configuration.
apt-cache show package_name Display information about a particular package.

The dpkg command

In addition to apt utilities, you can use the dpkg command to interact with the package manager.

The dpkg -l lists the installed packages. The dpkg -S path_to_file display the package that the file belongs to. The dpkg -L package_name list all files in package. And to install a .deb package, use dpkg -i package_name.deb.

Command Meaning
dpkg -l List installed packages.
dpkg -S path_to_file Display the package that the file belongs to.
dpkg -L package_name List all files in package.
dpkg -i package_name.deb To install a .deb package.

References & Resources

  • N/A