Fermi Red Hat Linux basis of installation is RPM. It is a program that can be used to install, uninstall, query, verify, and build software packages. It is also available for other platforms such as Sun, DEC, etc.
I. RPM Particulars
A. Package Name
1. packagename-version-patchlevel.architecture.rpm
a. i.e., XFree86-3.3.2.3-18.i386.rpm
packagename - XFree86
version - 3.3.2.3
patchlevel - 18
architecture - i386 (i.e., Intel based) or noarch
rpm
B. RPM Database Files
1. Several database files reside in /var/lib/rpm describing what is
currently installed on a system. Can't really do anything with them outside
of RPM. This is where they live.
confilictsindex.rpm
fileindex.rpm
groupindex.rpm
nameindex.rpm
packages.rpm
providesindex.rpm
requiredby.rpm
triggerindex.rpm
II. Four Main Modes of Operation
A. Install
1. rpm -i packagename-version-patchlevel.arch.rpm
2. Options
--test Don't install, just test and report problems
-U Upgrade an installed package. Uninstalls old package and installs new
-h print 50 hash marks while installing, shows amount completed
-v verbose. What package is being installed, useful when used with the
-h option.
B. Uninstall
1. rpm -e packagename[-version-patch] NOTE: arch.rpm cannot be used
2. Options
--test Don't uninstall, just test and report problems
--nodeps Don't check dependencies before uninstalling.
C. Query
1. rpm -q packagename[-version-patch] NOTE: arch.rpm cannot be used
2. Options
a. -i Display information about the package, e.g.
sapphire.fnal.gov% rpm -qi XFree86
Name : XFree86 Version : 3.3.2 Release : 13 Install date: Thu Jul 16 08:33:19 1998 Group : X11/XFree86 Size : 12019528 Packager : Red Hat Software <[email protected]> Summary : XFree86 Window System servers and basic programs |
Distribution: Manhattan Vendor: Red Hat Software Build Date: Mon Jun 8 22:10:54 1998 Build Host: porky.redhat.com Source RPM: XFree86-3.3.2-13.src.rpm |
Description :
X Windows is a full featured graphical user interface featuring multiple
windows, multiple clients, and different window styles. It is used on
most Unix platforms, and the clients can also be run under other popular
windowing systems. The X protocol allows applications to be run on either
the local machine or across a network, providing flexibility in client/server
mplementations.
This package contains the basic fonts, programs and documentation for an
X
workstation. It does not provide the X server which drives your video
hardware -- those are available in other package.
-f <file> Query what package <file> belongs to. Note: <file>
must the
absolute path to a file, e.g. rpm -qf /usr/bin/X11/Xconfigurator will
fail since X11 is a symbolic link to /usr/X11R6/bin
-l List all files that are part of the package
--scripts List all scripts that run before when (un)installing
D. Verifying Files and Packages
1. rpm -V packagename[-version-patch]
2. Output format
a. The output given by rpm -V is a series of letters and periods depending
on if a file passes (a period) or fails (a letter). Here's an example of
the output of doing an rpm -V initscripts:
S.5....T c /etc/inittab
S.5....T c /etc/rc.d/rc.local
missing /etc/rc.d/rc3.d/S15nfsfs
missing /etc/rc.d/rc4.d/S15nfsfs
missing /etc/rc.d/rc5.d/S15nfsfs
S.5....T c /etc/sysconfig/network-scripts/ifcfg-lo
b. Here's a key to the letters:
5 MD5 sum
S File size
L Symlink
T Mtime
D Device
U User
G Group
M Mode (includes permissions and file type)
c configuration file
As you can see, the file /etc/inittab has been changed since it was installed, the size, the MD5 sum and the time it was last touched have all changed. This is normal in this case since I've changed my runlevel and added a few goodies. Things to watch out for are MD5 sum changes on such utilities as 'ls' 'chsh' 'chfn' etc.
3. Options
-f <file> Useful for verifying the package that <file> belongs to.
-a Useful for performing a verification on an entire system. This
should be performed after installing Linux for the first time, and
save the output to a file.