Sections
The compressed files in Unix
Essentials
·
Uncompress a .Z file : uncompress
<fichier.Z>
· Uncompress a .gz file : gzip -d <file.gz>
· Uncompress a .bz2 file : bzip2 -d <file.bz2>
· Extract a .tar file : tar xvf <file.tar>
· Extract a .zip file : unzip <file.zip>
· Uncompress a .gz file : gzip -d <file.gz>
· Uncompress a .bz2 file : bzip2 -d <file.bz2>
· Extract a .tar file : tar xvf <file.tar>
· Extract a .zip file : unzip <file.zip>
Combinations
·
Extract a .tgz, or .tar.gz file : tar zxvf
<file.tgz>
· Extract a .tar.bz2 file : tar jxvf <file.tar.bz2>
· Extract a .rpm file : rpm2cpio <file.rpm> | cpio -mid
· Extract a .tar.bz2 file : tar jxvf <file.tar.bz2>
· Extract a .rpm file : rpm2cpio <file.rpm> | cpio -mid
Iso images:
·
Mount a .iso file : mount -o
loop -t iso9660 <file.iso> /mountpoint
The less common:
·
Extract a .deb file : ar xv
<file.deb> (ar appartient au package
binutils)
· Extract a .rar file : unrar x <file.rar> (unrar can be downloaded from rarlab.com)
· Extract a .ace file : unace x <file.ace> (unace ("LinUnAce") can be downloaded from winace.com)
· Extract a .lha file : lha x <file.lha or file.lzh>
· Extract a .jar file : jar xvf <file.jar>
· Extract a .xpi file : The xpi files are actually jar file: jar xvf <file.xpi>
· Extract a .7z file : 7za x <file.7z> (7za can be downloaded from p7zip Sourceforge page)
· Extract a Microsoft .cab file : cabextract <file.cab> (cabextract can be downloaded from uklinux.net)
· Extract a .cab InstallShield : unshield <file.cab> (unshield can be downloaded from synce.sourceforge.net)
· Extract a arj file : unarj x <file.arj> (unarj belongs to the package "Bin", and a full version is available from arj.sourceforge.net (in which case we will use arj x instead of unarj x)
· Extract uuencoded files, or base64 encoded files: uudeview -i <file>
· Extract a .rar file : unrar x <file.rar> (unrar can be downloaded from rarlab.com)
· Extract a .ace file : unace x <file.ace> (unace ("LinUnAce") can be downloaded from winace.com)
· Extract a .lha file : lha x <file.lha or file.lzh>
· Extract a .jar file : jar xvf <file.jar>
· Extract a .xpi file : The xpi files are actually jar file: jar xvf <file.xpi>
· Extract a .7z file : 7za x <file.7z> (7za can be downloaded from p7zip Sourceforge page)
· Extract a Microsoft .cab file : cabextract <file.cab> (cabextract can be downloaded from uklinux.net)
· Extract a .cab InstallShield : unshield <file.cab> (unshield can be downloaded from synce.sourceforge.net)
· Extract a arj file : unarj x <file.arj> (unarj belongs to the package "Bin", and a full version is available from arj.sourceforge.net (in which case we will use arj x instead of unarj x)
· Extract uuencoded files, or base64 encoded files: uudeview -i <file>