Linux common compression decompression command set

  

.tar Unpacking: tar xvf FileName.tar Package: tar cvf FileName.tar DirName (Note: tar is packaged, not compressed!) .gz Unzip 1: gunzip FileName.gz Unzip 2: gzip -d FileName.gz Compress: gzip FileName .tar.gz and .tgz Extract: tar zxvf FileName.tar.gz Compress: tar zcvf FileName.tar.gz DirName .bz2 Unzip 1: bzip2 -d FileName.bz2 Unzip 2: bunzip2 FileName.bz2 Compression: bzip2 -z FileName .tar.bz2 Extract: tar jxvf FileName.tar.bz2 Compress: tar jcvf FileName.tar.bz2 DirName .bz Unzip 1: bzip2 -d FileName.bz Unzip 2: bunzip2 FileName.bz Compress: Unknown .tar.bz Unzip: tar jxvf FileName.tar.bz Compress: Unknown .Z Unzip: uncompress FileName.Z Compress: compress FileName .tar.Z Unzip: tar Zxvf FileName.tar.Z Compression: tar Zcvf FileName.tar.Z DirName .zip Unzip: unzip FileName.zip Compress: zip FileName.zip DirName -a Convert file to ASCII mode -F Try to repair corrupted compressed file -h Display help interface -m Compress file After deleting the source file -n specific string does not compress the file with a specific suffix string -o set the latest change time of all files in the compressed file to the time when compression -q quiet mode, does not display when compressed Execution of the instruction -r Process all subdirectories under the specified directory together with the file -S Contains system files and hidden files (S is uppercase) -t Date Sets the last modified date of the compressed file to the specified date, date The format is mmddyyyy. For example: let's say the most common one. Pack the /opt/abc directory to /opt/abc.zip # zip -r /opt/abc.zip /opt/abc///The parameters are generally -r

.rar Unzip: rar x FileName.rar Compress: rar a FileName.rar DirName rar please go to: http://www.rarsoft.com/download.htm Download! After extracting, please copy rar_static to the /usr/bin directory (other directories specified by the $PATH environment variable): [root@www2 tmp]# cp rar_static /usr/bin/rar .lha Unzip: lha -e FileName. Lha Compression: lha -a FileName.lha FileName lha Please go to: http://www.infor.kanazawa-it.ac.jp/~ishii/lhaunix/Download! > After decompressing, please copy lha to the /usr/bin directory (other directories specified by the $PATH environment variable): [root@www2 tmp]# cp lha /usr/bin/.rpm Unpacking: rpm2cpio FileName. Rpm |  Cpio -div .deb unpacking: ar p FileName.deb data.tar.gz |  Tar zxf - .tar .tgz .tar.gz .tar.Z .tar.bz .tar.bz2 .zip .cpio .rpm .deb .slp .arj .rar .ace .lha .lzh .lzx .lzs .arc . Sda .sfx .lnx .zoo .cab .kar .cpt .pit .sit .sea Extract : sEx x FileName.* Compression : sEx a FileName.* FileName

sEx just calls the relevant program, itself is not compressed , decompression function, please pay attention! sEx please go to: http://sourceforge.net/projects/sexdownload! After unzipping, please copy sEx to the /usr/bin directory (other directories specified by the $PATH environment variable): [root@www2 tmp]# cp sEx /usr/bin/Uncompress and compile: sudo ./configure make make Install of course, the compiler must be root user, and the decompression is not necessarily, ordinary users are why. The above are commonly used commands. The following are the commands that are not commonly used. Here are the pictures that are given to the brothers. You can read them at that time. Method 2: sudo ./configure --prefix=/path make ; make install Method 3: sudo ./configure --enable-static-link \\ --prefix=$XXX/static --with-curses && make && make install

Copyright © Windows knowledge All Rights Reserved