From the course: Red Hat Certified System Administrator (EX200) Cert Prep: 1 Deploy, Configure, and Manage (2021)

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Compress files and archives

Compress files and archives

- [Instructor] When we're using tar to create archives, it's easy to pass a compressor to make the archives smaller. However, these compressors can be used separately as well. We might want to use a compressor without tar if we just want to make one file smaller and weren't concerned about the metadata like file ownership, permissions or timestamps. Note that some compressors don't work well with recursive directories so tar would be the best bet for that case. The first compressor we'll look at is gzip as we've seen in a previous video to create a tar archive and call it gzip we just pass the dash dash gzip option to tar, to create a gzip archive without tar we use it directly. Let's copy the slash Etsy services file to our current directory so we have something to compress type in cp slash etc slash services space dot and hit enter. The source file is slash Etsy slash services and the destination is just a single dot. The…

Contents