Basic Commands in Linux With Examples
Basic Commands in Linux With Examples
compression method:
Gunzip bunzip2 XZ
1- extension file .gz .bz2 .xz
2- compression speed is speed is slow speed is very
slow
very fast than gunzip than any.
3- compression ratio is ratio is better ratio is too
less than bunzip and XZ than gunzip good than other
*************************************************************************
*****
Only for Achive==>
Syntax: # tar -<option> <archieve filename.tar> <source1>
<source2> <source3>
Option:
c= to create archieve
r= to append the data in Tar file.
t= to check list of data in tar file
v= Verbose
x= extract
f= from file (mendatory)
C= to change the extract location
******************************************************
z= compress with gunzip method
j= compress with bunzip2 method
J= compress with xz method
*****************************************************
For Archieve:
For Compress:
czvf= to compress in gunzip #tar -czvf Network.tar.gz abc1 abc2 abc3
cjvf= to compress in bunzip2 #tar -cjvf Network.tar.bz2 abc1 abc2 abc3
cJvf= to compress in xz #tar -cJvf Network.tar.xz abc1 abc2 abc3
*************************************************************************
***
Difference of Command:
2- gzip
3- bzip2 Only commpress==> 1- any normal file
4- xz But original file 2- any tar file
of both type
*************************************************************************
Create compress in Gunzip:
# gunzip <filename.gz>
*************************************************************************
*
# bunzip2 <filename.bz2>
*************************************************************************
*
Create compress in XZ:
# xz -d <filename.xz>
*************************************************************************
*