Google News
logo
Linux - Interview Questions
How do you compress and decompress files in Linux?
To compress files in Linux, you can use the tar command along with gzip compression.

For example : If we want to create a file name “shivaji” with gzip compression. We use the following command.
tar -czvf shivaji.tar.gz files?

This command will create a compressed archive file containg the specified “files

To decompress the same, we use the following command.
tar -xzvf shivaji.tar.gz?
Advertisement