Pete Freitag Pete Freitag

Searching for installed RPM packages

Updated on November 07, 2024
By Pete Freitag

Suppose you want to search the rpm's installed on a linux server that uses rpm (the Redhat Package Manager). I find the easiest way to query is by doing something like this:

rpm -qa | grep httpd

The -qa will list all installed rpm's, then we can pipe a grep to search the list.

More about Grep

Grep is a pretty handy command to know on RedHat Linux (or Amazon Linux, or CentOS or whatever you are using). You can perform an Inverted / Negative grep search to find lines that do not match. You can count files by extension using grep. You can also do a case insensitive grep search if you need to. Grep is one of the most useful linux commands to know!



redhat rpm linux

Searching for installed RPM packages was first published on December 14, 2005.

If you like reading about redhat, rpm, or linux then you might also like:

Discuss / Follow me on Twitter ↯