Find out rpm package architecture of an installed RPM (installation such as i386 or x86_64 bit)

Almost all rpm package has i386 or x86_64 added to RPM file extension. However some times you may see file name such as file-version.rpm. You can list all installed rpm packages with rpm -qa command but it will not display architecture. You can run following command to display rpm package architecture:
rpm -qa --qf "%{n}-%{arch}\n"

output as below

dbus-glib-x86_64
nss-i386
dbus-glib-i386
gnutls-i386
libxml2-i386

Leave a Reply

Your email address will not be published. Required fields are marked *

*