Skip to content
Related Articles
Get the best out of our app
Open App

Related Articles

Difference Between APT and DPKG in Ubuntu

Improve Article
Save Article
Like Article
Improve Article
Save Article
Like Article

What is APT?

APT (Advanced Package Tool) is a free software user interface for Debian and Debian-based Linux distributions that interacts with core libraries to handle program installation and removal. APT is a package that contains a set of utilities called apt. A large component of APT is specified in a C++ function library; APT also contains command-line applications for interacting with packages that utilize the library. Apt, apt-get, and apt-cache are three such applications. Because they are easy and common, they are frequently used in examples. In all current Debian versions, the apt package has “important” priority and is thus included in a basic Debian installation. APT is a front-end to dpkg that is more user-friendly than the earlier select front-end. While dpkg handles individual package activities, APT handles package relationships (particularly dependencies), as well as the sourcing and administration of higher-level versioning choices (release tracking and version pinning).

APT is frequently praised as one of Debian’s greatest features, which Debian’s developer’s credit to the policy’s tight quality standards. The method APT calls dpkg is one of its most notable features: it performs topological sorting of the list of packages to be installed or uninstalled before calling dpkg in the best possible order. It uses the –force options of dpkg in several circumstances. It only does this if it can’t figure out how to avoid the reason dpkg requires the action to be forced.

What is DPKG?

The package management system of the free operating system Debian and its many variations is based on the program DPKG. DPKG is a command that may be used to install, uninstall, and display information about .deb packages. dpkg (Debian Package) is a low-level utility in and of itself. APT (Advanced Package Program), a higher-level tool, is more popular than dpkg because it can retrieve packages from distant places and handle complicated package relationships, such as dependency resolution. APT frontends such as aptitude (ncurses) and synaptic (GTK) are utilized because of their more user-friendly interfaces.

Dpkg-deb, dpkg-split, dpkg-query, dpkg-statoverride, dpkg-divert, and dpkg-trigger are all included in the Debian package “dpkg.” Programs like update-alternatives and start-stop-daemon are also included. The install-info software was formerly included, but it was subsequently removed since it is now developed and released independently.  The various build tools detailed below are included in the Debian package “dpkg-dev.”

 Difference Between APT and DPKG




1 In APT Packages from external repositories can be downloaded. In Dpkg Packages from external repositories cannot be downloaded.
2 APT has the ability to resolve dependencies DPKG doesn’t have such ability.
3 APT installs local Packages using dpkg. DPKG also supports local package installation.
4 APT doesn’t terminate if you try to install a package whose dependencies are missing. APT downloads the dependencies. Dpkg will terminate and report missing dependencies if you try to install a package with it’s dependencies missing.
5 APT Setup a remote package installation. DPKG doesn’t support remote package installation.
6 APT is in charge of the system’s package listings. It also takes care of package dependencies, ensuring that when one package is installed, all of the others that it requires are likewise installed. It can also get packages from package repositories. The low-level utility dpkg is responsible for installing package contents on the system.

Installs or upgrades <package> and all of its dependencies after downloading them. This will also remove a shipment that has been placed on hold.

apt-get install <package>

Installs a Debian package file, such as the one you manually downloaded.

dpkg -i <package.deb>

Removes the package <package> as well as any packages that are dependent on it. —purge indicates that packages should be purged; for additional details, see dpkg -P.

apt-get remove [--purge] <package>

Removes a package called package> that has been installed.

dpkg -r <package> 
My Personal Notes arrow_drop_up
Last Updated : 02 Jun, 2022
Like Article
Save Article
Similar Reads
Related Tutorials