1. Creating an uncompressed tar Archive using option -cvf : This command creates a tar file called file.tar which is the Archive of all .c files in current directory.
$ tar cvf file.tar *.c
Output :
os2.c os3.c os4.c
2. Extracting files from Archive using option -xvf : This command extracts files from Archives.
$ tar xvf file.tar
Output :
os2.c os3.c os4.c
3. gzip compression on the tar Archive, using option -z : This command creates a tar file called file.tar.gz which is the Archive of .c files.
$ tar cvzf file.tar.gz *.c
4. Extracting a gzip tar Archive *.tar.gz using option -xvzf : This command extracts files from tar archived file.tar.gz files.
$ tar xvzf file.tar.gz
COMMENTS