How to list/sort all the RPM packages installed in your Linux server.

Below is the command I use to list or sort all the packages installed in my linux system.

rpm -qa –queryformat “%{GROUP} %{NAME}-%{VERSION}\n” | sort

 Sample Output:

Applications/Archiving cpio-2.10
Applications/Archiving pax-3.4
Applications/Archiving tar-1.23
Applications/Archiving unzip-6.0
Applications/Archiving zip-3.0
Applications/Databases db4-utils-4.7.25
Applications/Databases mysql-5.1.71
Applications/Databases mysql-libs-5.1.71
Applications/Databases mysql-server-5.1.71
Applications/Databases ntteam-MySQL-shared-5.5.28
Applications/Databases postgresql-8.4.13
Applications/Databases postgresql-libs-8.4.13
Applications/Databases postgresql-odbc-08.04.0200
Applications/Databases PyGreSQL-3.8.1
Applications/Databases python-psycopg2-2.0.14
Applications/Databases sqlite-3.6.20
Applications/Editors nano-2.0.9
Applications/Editors vim-common-7.2.411
Applications/Editors vim-enhanced-7.2.411
Applications/Editors vim-minimal-7.2.411
Applications/Emulators virt-what-1.11
Applications/Engineering bc-1.06.95
Applications/File bzip2-1.0.5
Applications/File file-5.04
Applications/File file-libs-5.04
Applications/File findutils-4.4.2
Applications/File gzip-1.3.12
Applications/File scl-utils-20120927
Applications/File xz-4.999.9
Applications/Internet curl-7.19.7
Applications/Internet elinks-0.12
Applications/Internet mailx-12.4
Applications/Internet mtr-0.75
Applications/Internet nc-1.84
Applications/Internet openssh-5.3p1
Applications/Internet openssh-clients-5.3p1
Applications/Internet rsync-3.0.6
Applications/Internet tcpdump-4.0.0
Applications/Internet telnet-0.17
Applications/Internet traceroute-2.0.14
Applications/Internet webalizer-2.21_02
Applications/Internet wget-1.12
Applications/Multimedia alsa-utils-1.0.22
Applications/Multimedia flac-1.2.1
Applications/Multimedia gstreamer-0.10.29
Applications/Multimedia gstreamer-plugins-base-0.10.29
Applications/Multimedia gstreamer-tools-0.10.29
Applications/Multimedia libvisual-0.4.0
Applications/Multimedia phonon-backend-gstreamer-4.6.2
Applications/Multimedia theora-tools-1.1.0
Applications/Publishing ghostscript-8.70
Applications/Publishing ghostscript-fonts-5.50
Applications/Publishing groff-1.18.1.4