Linux+ Guide to Linux Certification

  • Published on
    25-Jan-2016

  • View
    33

  • Download
    6

Embed Size (px)

DESCRIPTION

Linux+ Guide to Linux Certification. Chapter 12 Compression, System Backup, and Software Installation. Objectives. Outline the features of common compression utilities Compress and decompress files using common compression utilities - PowerPoint PPT Presentation

Transcript

  • Linux+ Guide to Linux CertificationChapter 12Compression, System Backup, and Software Installation

    Linux+ Guide to Linux Certification, 2e

  • ObjectivesOutline the features of common compression utilitiesCompress and decompress files using common compression utilitiesPerform system backups using the tar, cpio, and dump commandsView and extract archives using the tar, cpio, and restore commands

    Linux+ Guide to Linux Certification, 2e

  • Objectives (continued)Use burning software to back up files to CD-RW and DVD-RWDescribe common types of Linux softwareCompile and install software packages from source codeUse the Red Hat Package Manager to install, manage, and remove software packages

    Linux+ Guide to Linux Certification, 2e

  • CompressionCompression: Process in which files are reduced in size by a compression algorithmCompression algorithm: Set of instructions used to systematically reduce a files contentsCompression ratio: Amount of compression occurring during compressionThree most common compression utilities:Compressgzipbzip2

    Linux+ Guide to Linux Certification, 2e

  • The compress Utilitycompress command: Used to compress files using Lempel-Ziv compression algorithmzcat command: Used to view contents of an archive created with compress or gzip to Standard Outputuncompress command: Used to decompress files compressed by compress command

    Linux+ Guide to Linux Certification, 2e

  • The compress Utility (continued)Table 12-1: Common options used with the compress utility

    Linux+ Guide to Linux Certification, 2e

  • The gzip UtilityGNU zip (gzip): Used to compress files using Lempel-Ziv compression algorithmVaries slightly from algorithm used by compressTypically yields better compression than compressUses .gz filename extension by defaultCan control level of compression gunzip command: Used to decompress .gz files

    Linux+ Guide to Linux Certification, 2e

  • The gzip Utility (continued)Table 12-2: Common options used with the gzip utility

    Linux+ Guide to Linux Certification, 2e

  • The gzip Utility (continued)Table 12-2 (continued): Common options used with the gzip utility

    Linux+ Guide to Linux Certification, 2e

  • The gzip Utility (continued)Table 12-2 (continued): Common options used with the gzip utility

    Linux+ Guide to Linux Certification, 2e

  • The bzip2 Utilitybzip2 command: Used to compress files using Burrows-Wheeler Block Sorting Huffman Coding compression algorithmCannot compress directory full of filesCannot use zcat and zmore to view files Must use bzcat commandCompression ratio is 50% to 75% on averagebunzip2 command: Used to decompress files compressed via bzip2

    Linux+ Guide to Linux Certification, 2e

  • The bzip2 Utility (continued)Table 12-3: Common options used with the bzip2 utility

    Linux+ Guide to Linux Certification, 2e

  • The bzip2 Utility (continued)Table 12-3 (continued): Common options used with the bzip2 utility

    Linux+ Guide to Linux Certification, 2e

  • System BackupSystem backup: Process whereby files are copied to an archiveArchive: Location (file or device) that contains copy of filesTypically created by a backup utilityShould backup user files from home directories and any important system configuration filesPossibly files used by system services, as wellSeveral backup utilities availabletar, cpio, dump/restore, burning software

    Linux+ Guide to Linux Certification, 2e

  • System Backup (continued)Table 12-4: Common tape device files

    Linux+ Guide to Linux Certification, 2e

  • The tar UtilityTape archive (tar) utility: One of oldest and most common backup utilitiesCan create archive in a file on a filesystem or directly on a deviceAccepts options to determine location of archive and action to perform on archive

    Linux+ Guide to Linux Certification, 2e

  • The tar Utility (continued)Table 12-5: Common options used with the tar utility

    Linux+ Guide to Linux Certification, 2e

  • The tar Utility (continued)Table 12-5 (continued): Common options used with the tar utility

    Linux+ Guide to Linux Certification, 2e

  • The tar Utility (continued)tar utility does not compress files inside archiveTime needed to transfer archive across a network is highCan compress archiveBacking up files to compressed archive on a filesystem is useful when transferring data across a networkIll suited to backing up large amounts of data for system recovery

    Linux+ Guide to Linux Certification, 2e

  • The cpio UtilityCopy in/out (cpio): Common backup utilityIncludes options similar to tar utilityHas added features Ability to back up device files Long filenamesUses absolute pathnames by default when archiving

    Linux+ Guide to Linux Certification, 2e

  • The cpio Utility (continued)Table 12-6: Common options used with the cpio utility

    Linux+ Guide to Linux Certification, 2e

  • The cpio Utility (continued)Table 12-6 (continued): Common options used with the cpio utility

    Linux+ Guide to Linux Certification, 2e

  • The dump/restore Utilitydump/restore: Used to back up files and directories to device or file on filesystemWorks with files on ext2 and ext3 filesystems/etc/dumpdates: File used to store information about incremental and full backups

    Linux+ Guide to Linux Certification, 2e

  • The dump/restore Utility (continued)Full backup: Archiving all data on filesystemIncremental backup: Backs up only data that has changed since last backuprestore command: Extract archives created with dump

    Linux+ Guide to Linux Certification, 2e

  • The dump/restore Utility (continued)Figure 12-1: A sample backup strategy

    Linux+ Guide to Linux Certification, 2e

  • The dump/restore Utility (continued)Table 12-7: Common options used with the dump/restore utility

    Linux+ Guide to Linux Certification, 2e

  • Burning Softwaretar, cpio, and dump utilities copy data to backup medium in character-by-character or block-by-block formatTypically used with tape, floppy, and hard disk mediaBurning software: Used to write files to CD-RW or DVD-RW mediaRed Hat Fedora Core 2 comes with X-CD-Roast

    Linux+ Guide to Linux Certification, 2e

  • Burning Software (continued)Figure 12-2: The X-CD-Roast program

    Linux+ Guide to Linux Certification, 2e

  • Software InstallationSoftware for Linux can consist of: Binary files precompiled to run on certain hardware architectures Source code, which must be compiledTypically distributed in tarball formatPackage manager: System that defines standard package format Used to install, query, and remove packagesRed Hat Package Manager (RPM): Most common package manager used by Linux systems today

    Linux+ Guide to Linux Certification, 2e

  • Compiling Source Code into ProgramsProcedure for compiling source code into binary programs standardized among most OSS developersGNU C Compiler (gcc): Command used to compile source code into binary programsAfter compilation, must move program files to appropriate directoryMakefile: Contains most of information and commands necessary to compile program

    Linux+ Guide to Linux Certification, 2e

  • Compiling Source Code into Programs (continued)Figure 12-3: The rdesktop program

    Linux+ Guide to Linux Certification, 2e

  • Installing Programs Using RPMPackages in RPM format have filenames that indicate hardware architecture for which the software was compiledEnd with .rpm extensionTo install an RPM package, use i option to rpm commandCommand used to install, query, and remove RPM packages

    Linux+ Guide to Linux Certification, 2e

  • Installing Programs Using RPM (continued)Figure 12-4: The bluefish program

    Linux+ Guide to Linux Certification, 2e

  • Installing Programs Using RPM (continued)Table 12-8: Common options used with the rpm utility

    Linux+ Guide to Linux Certification, 2e

  • Installing Programs Using RPM (continued)Table 12-8 (continued): Common options used with the rpm utility

    Linux+ Guide to Linux Certification, 2e

  • Installing Programs Using RPM (continued)Figure 12-5: Configuring Fedora core software packages after installation

    Linux+ Guide to Linux Certification, 2e

Recommended

View more >