Selects packages that require a | |
Selects a package with the given name. |
For example, to find out which package installed the file
$ rpm -qf
cdparanoia-libs-alpha9.8-25
Or to find out which packages provide
$ rpm -q --whatprovides
sendmail-8.13.4-2
postfix-2.2.2-2
Sometimes, though, you need more information than the name and version number of the packages selected. Table 5-2 lists the most common query output options.
Table 5-2. Query output options
Option | Description |
---|---|
--changelog | Shows the package changelog, a list of changes to the various versions of the package (not necessarily to various versions of the software). |
-c | Shows the configuration files included in the package. |
-d | Shows the documentation files included in the package. |
-l | Lists files included in the package. |
--filesbypkg | Same as -l, except that the package name is printed in front of each file; useful when multiple packages are selected. |
-i | Provides detailed information about the package (package description, license, group, origin, and so forth). |
--provides | Lists the capabilities provided by the package. |
--requires | Lists the capabilities required to successfully use the package. |
--scripts | Displays pre- and post-installation scripts, and pre- and post-uninstallation (removal) scripts. |
--triggers | Displays the trigger scripts in the package. Trigger scripts are invoked when another, related package is installed or removed. |
When output options and selection options are combined,
$ rpm
Name : sendmail Relocations: (not relocatable)
Version : 8.13.4 Vendor: Red Hat, Inc.
Release : 2 Build Date: Fri 06 May 2005 08:35:13 AM EDT
Install Date: Mon 29 Aug 2005 12:46:19 AM EDT Build Host: decompose.build.redhat.com
Group : System Environment/Daemons Source RPM: sendmail-8.13.4-2.src.rpm
Size : 1332268 License: Sendmail
Signature : DSA/SHA1, Fri 20 May 2005 01:44:43 PM EDT, Key ID b44269d04f2a6fd2
Packager : Red Hat, Inc. <http://bugzilla.redhat.com/bugzilla>
Summary : A widely used Mail Transport Agent (MTA).
Description :
The Sendmail program is a very widely used Mail Transport Agent (MTA).
MTAs send mail from one machine to another. Sendmail is not a client
program, which you use to read your email. Sendmail is a
behind-the-scenes program which actually moves your email over
networks or the Internet to where you want it to go.
If you ever need to reconfigure Sendmail, you will also need to have
the sendmail.cf package installed. If you need documentation on