How to Create .tar.gz Archive Using Terminal on Ubuntu 18.04 LTS?

2019-06-16 1

How to Create .tar.gz Archive Using Terminal on Ubuntu 18.04 LTS?

Step 1: Go to the Terminal, and then right click on it. Click on 'Open Terminal.'

Step 2: To Create type the command below:-

sudo tar -czvf name_of_archive.tar.gz path_to_Directory_or_file


If you have more than one files or directories that you want to compress, use command below:-


sudo tar -czvf name_of_archive.tar.gz path_to_Directory_1_or_file_1 path_to_Directory2_or_file_2 and so on.


c: It tells tar to create an Archive.

z: It tells the tar command to compress the archive using gzip.

v: It is verbose, it displays progress in the terminal while creating an archive.

f: It allows you to specify the filename of the archive.


Step 3: After typing, Hit Enter key on the keyboard, and your .tar.gz file will be created.


It's done


Thanks for watching, please like and subscribe

==============================================

https://www.facebook.com/HowtoTutorialsByAmit/

Free Traffic Exchange