From Andre Solheim on Fri, 03 Jul 1998
I am in the process og getting hold of Linux. Could you please tell me what RPM is, and what it does?
I hope you can mail the answer to me directly
André L Solheim
RPM is the Red Hat Package Management system. This is an freely published set of specifications and tools to allow Linux and Unix vendors to package their software in a way that is amenable to automated installation upgrade, removable and administration.
Although it has Red Hat's name in it --- it has been adopted by most of the major Linux distribution maintainers. The only to major holdouts are Debian and Slackware. (There are a number of small, special purpose Linux distributions that don't use any package management --- many fit on a single diskette or designed to be installed into a DOS subdirectory and run via LOADLIN).
Debian has developed their own package management format (usually seen with the .deb extension) and Slackware continues to use the tried and true "tarball" format with pkgadd (?) and some other tools to help a little bit.
However, you can easily install the RPM subsystem into any Linux that you want. You can also use RPM on some packages and continue to manually build others from tarballs (.tar.gz files). You can also convert between package formats using tools like 'alien' and 'rpm2cpio' (or you can just use Midnight Commander to open and work with .rpm files, just as you would any directory, .zip or .tar file etc --- what how I usually delve into RPM files if I'm not going to install them).
The RPM system as been ported to several flavors of Unix and is no longer a purely "Linux" thing. Some sites are using it to help maintain their Solaris, and HP-UX systems.
In the simplest form you can use commands like:... to install a package (foo version 1.2 in this example).
rpm -i foo-1.2.rpm
There are also GUI and menu drive frontends to using RPM .... but I usually use the command line.
You can also let rpm do the FTP for you with a command like:... and this will upgrade the bar version 2.2 package off of an internal ftp server (where I presumably have placed it after testing it on one of my sacrificial admin systems).
rpm -U ftp://myserver.myorg.net/upgrades/bar-2.2.rpm
Another trick I've used is to get the description of an rpm file without bothering to get the whole file (to decide which files I wanted to fetch). I do this with a command like:(I don't have a specific path and filename handy --- but this should show the idea). You can also get a list of the contents of a package with:
rpm -qpi ftp://ftp.redhat.com/..../contrib/.....rpm... or a list of files from an installed package with
rpm -qpl $SOME_RPM_FILEYou can also do things like list all of the packages that you have installed on the whole system (at least those that you've installed using RPM) with a command like:
rpm -ql $SOME_INSTALLED_PACKAGE... and you can verify a package with a command like:
rpm -qa... which will give you a summary of every change to the checksums, ownership, permission, timestamp, etc --- of every file that was part of the "foobar" package.
rpm -V foobar
Combining these in a relatively obvious way you can check every package on your system with the following:You can also find out which package a given file "belongs to" with a command like:
rpm -qa | xargs rpm -VYou can learn more about the RPM system by looking at their very own web site: http://www.rpm.org.
rpm -qf /some/file/that/was/installed/by/something
So, good luck on your new adventure. Have fun with Linux.