What RPM packages are installed?
[[email protected] packages]# Rpm-qa/////View all installed packages
[[email protected] packages]# rpm-qa libxkbfile/////-QA parking name
Libxkbfile-1.0.6-1.1.el6.x86_64
[[email protected] packages]# Rpm-qa vim////No
[[email protected] packages]# Rpm-qa vim*////No
[[email protected] packages]# Rpm-qa |grep vim*////No
[[email protected] packages]# Rpm-qa |grep vim////can be found
Vim-filesystem-7.4.629-5.el6.x86_64
Vim-minimal-7.2.411-1.8.el6.x86_64
Vim-common-7.4.629-5.el6.x86_64
Vim-enhanced-7.4.629-5.el6.x86_64
[[email protected] packages]# rpm-qa |grep ' vim* '////plus single quotes
Vim-filesystem-7.4.629-5.el6.x86_64
Device-mapper-libs-1.02.95-3.el6_7.3.x86_64
Vim-minimal-7.2.411-1.8.el6.x86_64
Vim-common-7.4.629-5.el6.x86_64
Sysvinit-tools-2.87-5.dsf.el6.x86_64
Device-mapper-1.02.95-3.el6_7.3.x86_64
.......
View the package details
[Email protected] packages]# Rpm-qi Gnome-python2-extras
See which files the package installs
[Email protected] packages]# RPM-QL Gnome-python2-extras
/usr/lib64/pkgconfig/gnome-python-extras-2.0.pc
/usr/share/doc/gnome-python2-extras-2.25.3
/usr/share/doc/gnome-python2-extras-2.25.3/authors
/usr/share/doc/gnome-python2-extras-2.25.3/changelog
/usr/share/doc/gnome-python2-extras-2.25.3/news
/usr/share/pygtk
/usr/share/pygtk/2.0
/usr/share/pygtk/2.0/defs
/usr/share/pygtk/2.0/defs/gtkhtml2.defs
/usr/share/pygtk/2.0/defs/trayicon.defs
See which package the file is installed on
[Email protected] packages]# rpm-qf/usr/share/pygtk/2.0/defs/gtkhtml2.defs
Gnome-python2-extras-2.25.3-20.el6.x86_64
Or
[email protected] packages]# which vim
/usr/bin/vim
[Email protected] packages]# Rpm-qf/usr/bin/vim
Vim-enhanced-7.4.629-5.el6.x86_64
[Email protected] packages]# RPM-QF ' which vim '
Error:file/mnt/packages/which vim: No file or directory
[[email protected] packages]# RPM-QF ' which vim '////anti-quote
Vim-enhanced-7.4.629-5.el6.x86_64
Linux Command-rpm query package