Show all installed packages or software in Linux, FreeBSD, OpenBSD

Q. I am using CentOS how do I show all installed packages in Linux?

ADVERTISEMENTS

A. You need to use rpm command to display all installed packages in Linux.

Red Hat/Fedora Core/CentOS Linux

Type the following command to get list of all installed software
# rpm -qa | less

Debian Linux

Type the following command to get list of all installed software:
# dpkg --get-selections

Ubuntu Linux

Type the following command to get list of all installed software:
# sudo dpkg --get-selections

FreeBSD

Type the following command to get list of all installed software:
# pkg_info | less
# pkg_info apache

Use pkg_version command to summarizes the versions of all installed packages:
# pkg_version | less
# pkg_version | grep 'lsof'

OpenBSD

OpenBSD also use pkg_info command to display list of all installed packages or software:
# pkg_info | less
# pkg_info apache

🐧 Get the latest tutorials on SysAdmin, Linux/Unix, Open Source/DevOps topics:
CategoryList of Unix and Linux commands
File Managementcat
FirewallCentOS 8 OpenSUSE RHEL 8 Ubuntu 16.04 Ubuntu 18.04 Ubuntu 20.04
Network Utilitiesdig host ip nmap
OpenVPNCentOS 7 CentOS 8 Debian 10 Debian 8/9 Ubuntu 18.04 Ubuntu 20.04
Package Managerapk apt
Processes Managementbg chroot cron disown fg jobs killall kill pidof pstree pwdx time
Searchinggrep whereis which
User Informationgroups id lastcomm last lid/libuser-lid logname members users whoami who w
WireGuard VPNCentOS 8 Debian 10 Firewall Ubuntu 20.04

ADVERTISEMENTS
17 comments… add one
  • sikamani May 23, 2008 @ 6:55

    yes this web site very use full to get the result

  • uday Sep 11, 2008 @ 2:18

    Thanks for the detailed info.

    I have a question:
    How can we list if a software in not in rpm format? is there any command/procedure to find them? Please let me know.

    • Gaurav Kumar Garg Jan 30, 2017 @ 14:30

      If it is not in rpm or apt format and its on your own distribution and not using any package manager then you need to go to /bin/* , /sbin/* etc directory and individually check it for eg:
      /bin/ls –version

  • Nagarjun Mar 2, 2009 @ 8:22

    can anyone compare installing a software in windows and in linux?

  • Nitin Kumar Sep 18, 2009 @ 9:06

    can some one help me… how to set up mail configuration on centos?

    • skyblaze Sep 24, 2014 @ 16:31

      depends upon the version/distro of Linux being used – recent distros like Ubuntu have made it basically painless as simple as point and click and is just as brainless as installing anything in Windows

  • Molinero Apr 18, 2011 @ 17:52

    Show all installed packages or software in Slackware

    Manually:
    # ls /var/log/packages

    By slapt-get
    # slapt-get –installed

  • Molinero Dec 5, 2011 @ 20:07

    Show all installed packages or software in Red Hat/Fedora Core/CentOS Linux with YUM

    # yum list installed

  • Eddie Mar 8, 2013 @ 7:15

    Can you tell me how to save the output of this command into a separate file?

    • John Apr 25, 2013 @ 13:05

      redirect the std out into a file with a command like this:

      rpm -qa | less > output.txt

  • Deepak May 8, 2013 @ 6:41

    If you want to save the output of some command, you can use redirect operation.
    For eg:
    To save the output of the command “yum list installed”, execute
    # yum list installed > installed_packages.txt
    where “installed_packages.txt” is the file where the output of the executed command
    is saved.

    This will be more helpful especially when the output of the command exceeds the
    screen space.

  • Raafi Jun 10, 2013 @ 0:19

    Any way of getting a list of the various commands to open up programs in the terminal? for example “Firefox” opens up a Firefox browser. I would like to be able to find a list of commands to open up all of the programs I have because when I look thru the list of “Show Applications” everything is not there. (I am working with Fedora 18)

  • Pinoy Oct 20, 2013 @ 9:40

    Thanks for the tutorial! :)

  • Geoff Jan 6, 2014 @ 22:38

    Even more useful

    $ yum list installed | sort | less
    or
    $ rpm -qa | sort > installed_software.txt

  • Suresh Apr 11, 2014 @ 6:57

    Good one… comprehensive

  • pravin jagtap Jul 31, 2014 @ 17:08

    /usr/bin/ld: cannot find -ll
    collect2: error: ld returned 1 exit status
    i have installed flex for fedora19 throug yumm install flex commmand but if i am compiling lex programe then this error ca occur pls help me what to do

  • waldir Aug 17, 2014 @ 10:11

    Does dpkg really list all *installed* packages? It seems to me like it should output only manually *selected/deselected* packages. That is quite a big difference.

Leave a Reply

Your email address will not be published.

Use HTML <pre>...</pre>, <code>...</code> and <kbd>...</kbd> for code samples.