Skip to main content
IBM  
Shop Support Downloads
IBM Home Products Consulting Industries News About IBM
IBM developerWorks : Linux : Education - Tutorials
LPI certification 102 exam prep, Part 1
ZIPPDF (letter)PDF (A4)e-mail
Main menuSection menuFeedbackPreviousNext
5. rpm, the (R)ed Hat (P)ackage (M)anager
  


Querying all installed packages page 10 of 16


You can query all the packages installed on your system by including the -a option. If you pipe the output through sort and into a pager, then it's a nice way to get a glimpse of what's installed on your system. For example:


# rpm -qa | sort | less
[output omitted]

Here's how many rpms we have installed on one of our systems:


# rpm -qa | wc -l
    287

And here's how many files are in all those rpms:


# rpm -qal | wc -l
  45706

Here's a quick tip: Using rpm -qa can ease the administration of multiple systems. If you redirect the sorted output to a file on one machine, then do the same on the other machine, you can use the diff program to see the differences.


Main menuSection menuFeedbackPreviousNext
Privacy Legal Contact