COMPRESSION:
tar cvf book.tar dir1 dir2 -->make tar file from 2 dir
tar tvf book.tar --> shows what is inside
tar xvf book.tar --> unpack book.tar into current directory
(first u make a *.tar than compress)
compress book.tar --> gives u book.tar.Z
-v book.tar --> verbose mode
uncompress book.tar.Z -->unpack into current dir or:
zcat book.tar.Z|tar xvf - -->unpack to current dir
zcat book.tar.Z|tar tvf - -->shows what inside
.gz
.gz
gzip file1 --> compress file1
-d file.gz --> open compression
compress with bzip2 is 67% stronger: bzip2 file.tar
--> file.tar.bz2
tar --preserver-permissions -cjvf backup.tar.bz2 /home
bzip2 -d file1.bz2 or tar jxvf file.tar.bz2
--> open bz2 compression
gunzip file1.gz --> upen compression
unzip file1.zip
|