Red Hat LINUX 7.2 - OFFICIAL LINUX CUSTOMIZATION GUIDE Manual page 249

Hide thumbs Also See for LINUX 7.2 - OFFICIAL LINUX CUSTOMIZATION GUIDE:
Table of Contents

Advertisement

Section 25.2:Using RPM
25.2.2 Installing
RPM packages typically have file names like foo-1.0-1.i386.rpm. The file name includes the
package name (foo), version (1.0), release (1), and architecture (i386). Installing a package is as
simple as typing the following command at a shell prompt:
# rpm -ivh foo-1.0-1.i386.rpm
foo
#
As you can see, RPM prints out the name of the package and then prints a succession of hash marks
as the package is installed as a progress meter.
Although a command like rpm -ivh foo-1.0-1.i386.rpm is com-
monly used to install an RPM package, you may want to consider using rpm
-Uvh foo-1.0-1.i386.rpm instead. -U is commonly used for up-
grading a package, but it will also install new packages. See Section 25.2.4,
Upgrading for more information about using the -U RPM option.
Installing packages is designed to be simple, but you may sometimes see errors:
Package Already Installed
If the package of the same version is already installed, you will see:
# rpm -ivh foo-1.0-1.i386.rpm
foo
#
If you want to install the package anyway and the same version you are trying to install is already
installed, you can use the --replacepkgs option, which tells RPM to ignore the error:
# rpm -ivh --replacepkgs foo-1.0-1.i386.rpm
foo
#
This option is helpful if files installed from the RPM were deleted or if you want the original config-
uration files from the RPM to be installed.
Conflicting Files
If you attempt to install a package that contains a file which has already been installed by another
package or an earlier version of the same package, you'll see:
####################################
Note
package foo-1.0-1 is already installed
####################################
249

Advertisement

Table of Contents
loading

This manual is also suitable for:

Linux 7.2

Table of Contents