1 / 44

Compression, backup, and software installation

Compression, backup, and software installation. Unit objectives Use compression utilities to compress and decompress files Perform system backups and view and extract archives Compile and install software packages from source code and use the Red Hat Package Manager. Topic A.

aletha
Download Presentation

Compression, backup, and software installation

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Compression, backup, and software installation Unit objectives • Use compression utilities to compress and decompress files • Perform system backups and view and extract archives • Compile and install software packages from source code and use the Red Hat Package Manager

  2. Topic A • Topic A: Compression • Topic B: System backup • Topic C: Software installation

  3. Compression • Process in which files are reduced in size by a compression algorithm • Compression algorithm • Instructions used to reduce the contents of a file

  4. Common compression utilities • compress • gzip • bzip2

  5. The compress utility • Uses LZW algorithm • Average ratio: 40-50% • zcat • Used to view the contents of archive created with compress or gzip • zmore • Used to view page-by-page • uncompress • Decompresses files that were processed with compress

  6. Common options with the compress utility

  7. GNU zip (gzip) • Algorithm varies slightly from that used by compress • Yields better compression • Typical ratio: 60-70%

  8. Common options with gzip continued

  9. Common options with gzip, continued

  10. The bzip2 utility • Uses a different algorithm from compress or gzip • zcat and zmore can’t be used • Average ratio: 50-75% • bzcat • Used to view the contents of archive created with bzip2 • bunzip2 • Used to decompress files

  11. Common options with bzip2

  12. Activity A-1 Compressing and uncompressing files

  13. Topic B • Topic A: Compression • Topic B: System backup • Topic C: Software installation

  14. System backup • Process of copying files to an archive • Archive • Location (file or device) that contains a copy of files • Typically created by a backup utility

  15. magnetic tape (mt) command • Used to control tape devices

  16. Activity B-1 Discussing backup media

  17. Backup utilities • tar • cpio • dump/restore • burning software

  18. Tape archive (tar) • One of the oldest and most common backup utilities • Accepts options to determine the location of the archive and the action to perform on the archive

  19. Common options with tar continued

  20. Common options with tar, continued

  21. Tarballs • A gzip-compressed tar archive • Used for software distribution as well as backup

  22. Activity B-2 Using the tar utility

  23. The copy in/out (cpio) utility • Common backup utility • Options similar to tar with added features • Can back up device files and long filenames • Uses absolute pathnames by default

  24. Common options with cpio

  25. The dump/restore utility • Full backup • Archives an entire filesystem • Incremental backup • Archives only files modified since the last full backup • Works only with files on ext2 and ext3 filesystems

  26. A sample backup strategy

  27. Options with dump/restore

  28. restore command • Extracts archives created with the dump command

  29. Activity B-3 Using cpio and dump utilities

  30. Topic C • Topic A: Compression • Topic B: System backup • Topic C:Software installation

  31. Forms of software distribution • Binary program files • Pre-compiled to run on specific hardware • Source code • Must be compiled on the local architecture • RPM package • Uses Red Hat Package Management system

  32. Source code • Independent of hardware platform • Procedure for compiling source code into binary programs is standardized among most open source developers • GNU C Compiler (gcc) • Used to compile source code into binary programs

  33. Package manager • Defines a standard package format • Can be used to install, query, and remove packages • Red Hat Package Manager (RPM) • The most commonly used

  34. Activity C-1 Discussing forms of software distribution

  35. Installing from source code • Uncompress and extract files • Run configure • Run make • Run make install

  36. Activity C-2 Compiling and installing a program from source code

  37. RPMs • Filenames indicate hardware architecture the software was compiled for • rpm command • Command used to install, query, and remove RPM packages

  38. Removing packages • Use RPM command with –e option

  39. Common options with RPM

  40. Red Hat Package Manager • Graphical tool that may be used to install RPM packages available with the GNOME/KDE desktop environment

  41. The RPM interface

  42. Activity C-3 Using RPM to query packages

  43. Activity C-4 Using RPM to install and remove software

  44. Unit summary • Compressed and decompressed files using compression utilities • Performed system backups and viewed and extracted archives • Compiled and installed software from source code and used the Red Hat Package Manager

More Related