gzip, tar Purpose file archiving -compressing multiple files into - - PowerPoint PPT Presentation

gzip tar purpose
SMART_READER_LITE
LIVE PREVIEW

gzip, tar Purpose file archiving -compressing multiple files into - - PowerPoint PPT Presentation

Unix/Linux Commands: gzip, tar Purpose file archiving -compressing multiple files into one smaller file -extracting/decompressing files from an archive -makes sharing files easier tar deals with its own format (.tar) Usage: gzip gzip


slide-1
SLIDE 1

gzip, tar

Unix/Linux Commands:

slide-2
SLIDE 2

Purpose

file archiving

  • compressing multiple files into one smaller file
  • extracting/decompressing files from an archive
  • makes sharing files easier

tar deals with its own format (.tar)

slide-3
SLIDE 3

Usage: gzip

gzip [options] [path ... ] examples: gzip fileToCompress gzip -d fileToDecompress gzip -r directoryToRecursivelyCompress gzip -c fileToCopyCompress > newArchiveName

slide-4
SLIDE 4

Options: gzip

  • c, --stdout

writes output to stdout (files unchanged)

  • d, --decompress

extract files from archive

  • r, --recursive

recursively act on all in the directory

slide-5
SLIDE 5

Options: gzip (cont.)

  • S .suf, --suffix .suf

end compressed file with .suf rather than .gz

  • 1-9, --fast, --best

set compression speed/quality from faster, less compression to better, slower compression

slide-6
SLIDE 6

Usage: tar

tar [functions] [options] [path … ] examples: tar -c -f newArchiveName fileOrDirToCompress tar -cf newArchiveName fileOrDirToCompress tar cf newArchiveName fileOrDirToCompress tar tf archiveToListFilesOf tar xf archiveToDecompress

slide-7
SLIDE 7

Functions: tar

  • c, --create

create new archive

  • t, --list

list files in archive

  • x, --extract, --get

extract files from archive

slide-8
SLIDE 8

Options: tar

  • f, --file=archiveName

specify name of archive to compress to

  • -overwrite
  • verwrite files when extracting
slide-9
SLIDE 9

Demonstration