Contact us

Print

Lab 7 - Managing and Installing Software

Table of contents:


Objectives

After completing this lab, you will be able to

- Install software from binary packages
- Compile and install software from source
- Query packages for information
- Resolve some basic dependencies issues

Estimated time to complete this lab: 40 minutes




BINARY FILES AND SOURCE FILES

The system you have built thus far is not a very complete system. You will find that one of your routine tasks is to install additional software, uninstall software and update already installed software.
There are generally two ways to install software in Linux. They can be installed from source or from precompiled binaries. The latter method is by far the easier way but it is also the least customizable. When you install from precompiled binaries most of the work has already been done for you. – but even then you do need to know the name and where to find the particular software you want.
Almost all software originally come as C or C++ programming language source files. The source programs are usually distributed as archives of source files. Usually tar’ed or gzip’ed or bzip2’ed files. This means they usually come compressed or as a single bundle.
Fortunately efforts have been made to standardize the form that source programs come in - this means that most developers have made their packages GNU standards. It also usually means that the packages will compile on any UNIX or UNIX like system ( e.g. Linux)

Source packages will usually contain the files named- README, INSTALL, NEWS
COPYING, configure, AUTHORS, ChangeLog? etc.

There are several different software or package managers that the various Linux distributions (distros) have standardized on. They all have different levels of functionality
There are also various front-end applications that have a graphical user interface for managing the software that come in already packaged forms. These applications are called package managers. Examples are:

The Red Hat Package Manager. The packages have the suffix “ .rpm”

The Debian package management system. The packages have the suffix “ .deb”


The most common syntax for the usage of the Red Hat package manager from the command line are:


rpm



Usage: rpm [OPTION...]

QUERYING AND VERIFYING PACKAGES:


       rpm {-q|--query} [select-options] [query-options]

       rpm {-V|--verify} [select-options] [--nodeps] [--nofiles] [--nomd5] 
                [--noscripts]

       rpm {-K|--checksig} [--nogpg] [--nopgp] [--nomd5] PACKAGE_FILE ...


INSTALLING, UPGRADING, AND REMOVING PACKAGES:

       rpm {-i|--install} [install-options] PACKAGE_FILE ...

       rpm {-U|--upgrade} [install-options] PACKAGE_FILE ...

       rpm {-F|--freshen} [install-options] PACKAGE_FILE ...

       rpm   {-e|--erase}   [--allmatches]   [--nodeps]   [--noscripts]   [--notriggers]
       [--repackage] [--test] PACKAGE_NAME ...

BUILDING PACKAGES:

       rpm {-ba|-bb|-bp|-bc|-bi|-bl|-bs} [build-options] SPECFILE ...

       rpm {-ta|-tb|-tp|-tc|-ti|-tl|-ts} [build-options] TARBALL ...

       rpm {--rebuild|--recompile} SOURCEPKG ...

MISCELLANEOUS:

       rpm {--initdb|--rebuilddb}

       rpm {--addsign|--resign} PACKAGE_FILE ...

       rpm {--querytags|--showrc}

       rpm {--setperms|--setugids} PACKAGE_NAME ...

SELECT-OPTIONS


[PACKAGE_NAME] [-a,--all] [-f,--file FILE] [-g,--group GROUP] 
[-p,--package PACKAGE_FILE]   [--querybynumber NUMBER]   
[--triggeredby PACKAGE_NAME]   [--whatprovides CAPABILITY] [--whatrequires CAPABILITY]




Created by: system. Last Modification: Saturday 04 of April, 2009 21:58:35 EST by wale.

...