Section 10.2. Linux Installation and Package Management


10.2. Linux Installation and Package Management

10.2.1. Objective 1: Design a Hard Disk Layout

10.2.1.1. Guidelines
  • Keep / small by distributing larger parts of the directory tree to other filesystems.

  • Separate a small /boot partition below cylinder 1024 for kernels.

  • Separate /var into its own partition to prevent runaway logs from filling /.

  • Separate /tmp.

  • Separate /usr if it is to be shared read-only among other systems via NFS.

  • Set swap size to be somewhere between one and two times the size of main memory.

10.2.2. Objective 2: Install a Boot Manager

10.2.2.1. LILO
  • LILO has historically been the default Linux boot loader.

  • LILO consists of the lilo command, which installs the boot loader, and the boot loader itself.

  • LILO is configured using /etc/lilo.conf.

10.2.2.2. GRUB
  • GRUB can boot Linux as well as most other PC-based operating systems.

  • GRUB relies on various files in the /boot/grub directory to support reading from various types of filesystems.

  • GRUB is configured using /boot/grub/menu.lst (or /boot/grub/grub.conf on some distributions).

  • GRUB can be configured to present a text or graphical menu interface and also has a command-line interface.

10.2.3. Objective 3: Make and Install Programs from Source

10.2.3.1. Source Files
  • Software often comes in a compressed tar archive file.

  • Larger source code packages include a configure script to verify that everything is in order to compile the software.

10.2.3.2. make
  • make is then used to build the software.

  • make is also often used to install the software into directories such as /usr/local/bin.

10.2.4. Objective 4: Manage Shared Libraries

10.2.4.1. Concepts
  • System libraries provide many of the functions required by a program.

  • A program that contains executable code from libraries is statically linked because it stands alone and contains all necessary code to execute.

  • Since static linking leads to larger executable files and more resource consumption, system libraries can be shared among many executing programs at the same time.

10.2.4.2. Commands
  • A program that contains references to external , shared libraries is dynamically linked at runtime by the dynamic linker, ld.so.

  • New locations for shared libraries can be added to the LD_LIBRARY_PATH variable. As an alternative, the locations can be added to /etc/ld.so.conf, which lists library file directories. After this, you must run ldconfig to translate this file into the binary index /etc/ld.so.cache.

10.2.5. Objective 5: Use Debian Package Management

10.2.5.1. Commands
  • dpkg automates the installation and maintenance of software packages and offers a number of options.

  • dselect uses a text based interactive menu to select (or deselect) packages for installation.

  • alien can install RPM packages on Debian-based systems .

  • apt-get is a powerful tool that interfaces with online repositories of Debian packages to install and upgrade Debian packages by package name and resolves each package's dependencies automatically.

10.2.6. Objective 6: Use Red Hat Package Manager (RPM)

10.2.6.1. Concepts
  • RPM automates the installation and maintenance of software packages.

  • Package dependencies are defined but not resolved automatically.

  • -i, -e, -U, -v, -h, --nodeps, and --force are common options.



LPI Linux Certification in a Nutshell
LPI Linux Certification in a Nutshell (In a Nutshell (OReilly))
ISBN: 0596005288
EAN: 2147483647
Year: 2004
Pages: 257

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net