How to Check a Particular Package is Installed on Linux

In Linux, software package management plays a crucial role in the seamless operation of a system that involves the installation, upgrading, configuration, and removal of software packages.

A package manager is a software tool that automates the management of software on a system by simplifying complex tasks such as installation, upgrading, and removal of software packages.

In this article, we will explore the importance of package management and provide a comprehensive guide on how to check whether a package is installed using a package manager in Linux systems.

1. Using APT and DPKG (Debian)

On Debian-based systems such as Ubuntu and Linux Mint, the APT (Advanced Packaging Tool) and dpkg (Debian Package Manager) are essential tools for managing software packages.

To check if a package is installed with APT or dpkg, you can use any of the following commands.

apt list --installed | grep <package-name>
dpkg -l | grep <package-name>

The command lists installed packages using apt or dpkg, and the grep command filters the output to show information about a specific package.

Find Specific Package Installation
Find Specific Package Installation

Replace <package-name> with the name of the package you want to check. If the package is installed, you will see relevant information; otherwise, there will be no output.

2. Using YUM and DNF (RHEL)

On Red Hat-based systems such as CentOS, Fedora, and Rocky and AlmaLinux, the YUM (Yellowdog Updater, Modified) and DNF (Dandified YUM) are the most commonly used package managers.

To check if a package is installed with yum or dnf, you can use any of the following commands.

yum list installed | grep <package-name>
dnf list installed | grep <package-name>
Check Specific Package Installation
Check Specific Package Installation

Alternatively, you can use the rpm command to check for the presence of a package.

rpm -qa | grep <package-name>

3. Using Pacman (Arch Linux)

On Arch Linux-based systems, such as Manjaro and Garuda, the Pacman is the default package manager and to check if a specific package is installed or not, use the following command.

pacman -Q | grep <package-name>

4. Using Zypper (SUSE Linux)

The package manager used on SUSE Linux distributions, including openSUSE, is called Zypper and to check whether a package is installed using Zypper, you can use it.

zypper search --installed-only <package-name>

Checking whether a package is installed through a package manager is a task that varies depending on the system and package manager you are using. The commands provided in this guide are general commands that can be used for specific needs.

Regularly verifying the status of installed packages is a good practice for system administrators and developers alike. It ensures that the required dependencies are present and helps to maintain a secure and well-functioning system.

Hey TecMint readers,

Exciting news! Every month, our top blog commenters will have the chance to win fantastic rewards, like free Linux eBooks such as RHCE, RHCSA, LFCS, Learn Linux, and Awk, each worth $20!

Learn more about the contest and stand a chance to win by sharing your thoughts below!

Ravi Saive
I am an experienced GNU/Linux expert and a full-stack software developer with over a decade in the field of Linux and Open Source technologies

Each tutorial at TecMint is created by a team of experienced Linux system administrators so that it meets our high-quality standards.

Join the TecMint Weekly Newsletter (More Than 156,129 Linux Enthusiasts Have Subscribed)
Was this article helpful? Please add a comment or buy me a coffee to show your appreciation.


Leave a Reply
  1. I use a Debian-based distro so I just use the “Installed” option with Synaptic.

    This is the 21st century. There is no need for magic spells and incantations of CLI anymore. Yes, CLI is useful IF you are a hobbyist or a developer or an experimenter. An everyday Linux user can use it without ever resorting to the command line.

    Imagine where Windows would be today if all the “pundits” and “experts” insisted that CLI is the way to productive computing.

    If it wasn’t for pundits and “experts” extolling the virtues of and need for CLI, Linux would be much more than just a blip on the computing landscape. While not approaching Windows in numbers, Linux would easily be more popular than OS/X.

    Today’s users DO NOT want to waste their time on arcane, esoteric, and cabalistic CLI. They just want to log on and start using their PCs.

    • @Dragonmouth,

      Absolutely agree! The convenience of GUI tools like Synaptic on Debian-based distros makes software management easy. While the CLI is powerful and is adopted by many users, such as developers and programmers, it’s all about making Linux accessible to everyone.


Got Something to Say? Join the Discussion...

Thank you for taking the time to share your thoughts with us. We appreciate your decision to leave a comment and value your contribution to the discussion. It's important to note that we moderate all comments in accordance with our comment policy to ensure a respectful and constructive conversation.

Rest assured that your email address will remain private and will not be published or shared with anyone. We prioritize the privacy and security of our users.