Search notes:
RPM
An RPM package is a
cpio package with some additional structures.
$ rpm -qf /usr/bin/man
man-db-2.6.7.1-16.fc21.x86_64
Find package's upstream URL:
$ rpm -qi man-db | grep -i url
URL : http://www.nongnu.org/man-db/
Apparently, the Debian equivalents are
$ dpkg -S /usr/bin/man
$ apt-cache show man-db | grep Homepage
View files in a of a package
The following command lists the files (but not the installaion scripts) of a package:
rpm -ql xyz.rpm
Extracting data from an RPM
RedHat provides the rpm2cpio
utility which extracts a cpio from an rpm package.
alien-pkg-convert is a
Perl utility than can convert RPM packges various other package formats (such as .deb)
Extract ONE file from an rpm package
The following command extracts the file /opt/abc/def.txt
from xyz.rpm
to /tmp/def.txt
.
Note: the path in the command is specified relatively (i. e. with a leading ./
):
$ rpm2cpio xyz.rpm | cpio -iv --to-stdout ./opt/abc/def.txt > /tmp/def.txt
See also
/etc/rpm
/etc/pki/rpm-gpg/
/var/lib/rpm