How to check .deb Package Dependencies in Ubuntu

Most software or application in Ubuntu, does not come as one package and it depends on other packages to work as intended. These supporting packages are called dependency packages as they are required for the proper working of the software. Usually, the package manager in your system automatically resolves these dependencies, but sometimes an issue or error occurs and you have to resolve the issue manually.

In that case, it is better to have a detailed picture of the dependencies of the package so that you can locate the issue easily. Therefore, You will learn how to check the dependencies of any package in this article.

Check
Sponsored
Dependencies Using APT Package Manager

You can use the apt package manager depends command to list down the dependencies associated with any particular package. For example, run the following command to see the dependencies of the vlc package.

sudo apt depends vlc

You can also use the following apt-cache command to get a similar result.

sudo apt-cache depends vlc

If you want more detailed information about package dependencies, run the following apt show command.

sudo apt show vlc

Similarly, you can use the apt-cache show command to get more comprehensive information about package dependencies.

sudo apt-cache show vlc

Check Dependencies Using Debian Package Manager (dpkg)

If you have to install any software from a deb file, you can check its dependencies by running one of the following commands.

sudo dpkg -I /path/to/package.deb
sudo dpkg --info /path/to/package.deb

Note: Replace /path/to/package with your deb file path before running the above command.

The above commands will show the dependencies even before the .deb package is installed. But if you want to check the dependencies of an already installed package, run the following command with your package name.

sudo dpkg -s firefox

Check Dependencies Using apt-rdepends Utility

apt-rdepends is a utility that can help you list down the package dependencies. You can install it by using the following command.

Sponsored
sudo apt install apt-rdepends

To see the dependencies tree, run the following command with your package name.

sudo apt-rdepends packagename

You can also get information about packages that are dependent on a particular package with the following command.

sudo apt-rdepends -r vlc-bin

Check Dependencies Using reverse-depends Utility

Reverse-depends is a utility that provides information about the dependent packages. You can install it by running the following command.

sudo apt install ubuntu-dev-tools

To list down the direct dependencies of the package, run the following command with your package name.

sudo reverse-depends -R vlc

Check Dependencies Using Simulated Installation/Uninstallation

You can use the -s option with the apt command to simulate the installation and uninstallation of any package to see the dependencies installed during the installation.

sudo apt install -s vlc

sudo apt remove -s php

Conclusion

Ubuntu/Linux packages are interdependent as they are designed to complete a single task. This article shows how you can see the package dependencies.

It is beneficial to know what packages are required or are being installed during software installation as it gives you more clarity over the installation process. It also helps you debug your installation process in case of an error.

The post How to check .deb Package Dependencies in Ubuntu appeared first on FAQforge.

Ubuntu Server Admin

Recent Posts

Canonical Releases Ubuntu 25.04 Plucky Puffin

The latest interim release of Ubuntu introduces “devpacks” for popular frameworks like Spring, along with…

2 days ago

Ubuntu 25.04 (Plucky Puffin) Released

Ubuntu 25.04, codenamed “Plucky Puffin”, is here. This release continues Ubuntu’s proud tradition of integrating…

3 days ago

Extended Security Maintenance for Ubuntu 20.04 (Focal Fossa) begins May 29, 2025

Ubuntu released its 20.04 (Focal Fossa) release 5 years ago, on March 23, 2020. As…

3 days ago

Ubuntu 20.04 LTS End Of Life – activate ESM to keep your fleet of devices secure and operational

Focal Fossa will reach the End of Standard Support in May 2025, also known as…

4 days ago

Ubuntu MATE 25.04 Release Notes

Ubuntu MATE 25.04 is ready to soar! 🪽 Celebrating our 10th anniversary as an official…

4 days ago

Ubuntu Weekly Newsletter Issue 887

Welcome to the Ubuntu Weekly Newsletter, Issue 887 for the week of April 6 –…

6 days ago