How to list installed packages on Debian

This short guide shows you how to get a list of all installed Packages on Debian Linux. Packages on Debian get installed with the apt package installer. We will use the dpkg command, which is part of the apt toolset, to query the installed packages database.

Get all installed Debian packages

dpkg --get-selections

As you can see, this command will show you a rather long list. To save the list to a file, use this command:

dpkg --get-selections > /tmp/packages.txt

We save the list in the file /tmp/packages.txt.

To scroll step by step through the package list, use:

dpkg --get-selections | more

Here is the result:

Sponsored

Sponsored

If you seek a specific package, use the grep command:

dpkg --get-selections | grep nginx

will show you all packages that contain the word “Nginx” in their name.

Example:

root@sv1:/# dpkg --get-selections | grep nginx
nginx-common                                    install
nginx-extras                                    install

The post How to list installed packages on Debian appeared first on FAQforge.

Ubuntu Server Admin

Recent Posts

Join Canonical at HPE Discover Las Vegas 2025

Canonical, the publisher of Ubuntu and trusted open source solutions provider, is proud to sponsor HPE Discover Las…

9 hours ago

Ubuntu Weekly Newsletter Issue 896

Welcome to the Ubuntu Weekly Newsletter, Issue 896 for the week of June 8 –…

1 day ago

Karafka 2.5 and Web UI 0.11: Next-Gen Consumer Control and Operational Excellence

Introduction Imagine pausing a problematic partition, skipping a corrupted message, and resuming processing - all…

2 days ago

How to Install and Run Mail-in-a-Box on Ubuntu VPS

This step-by-step guide will show you how to install and run Mail-in-a-Box on Ubuntu VPS.…

2 days ago

How to Deploy Keycloak on Ubuntu VPS

Here’s a clear and detailed how-to guide for how to deploy Keycloak on Ubuntu VPS.…

2 days ago

Canonical delivers Kubernetes platform and open-source security with NVIDIA Enterprise AI Factory validated design

Reference architectures speed up time to market for agentic AI projects To ease the path…

6 days ago