Linux Tar Decompression Command summary

Source: Internet
Author: User
Tags bz2

Summary of commonly used tar decompression commands, as a memo:tar-c:  to establish a compressed file-x: Decompression-T: View Content-r: Append files to the end of the compressed archive-u: Update the files in the original package this five is a separate command, compressed decompression to use one of them, Can be used with other commands but only one. The following parameters are optional when compressing or extracting files as needed. -Z:-j with gzip properties:-Z with bz2 property:-V with compress attribute: Show all procedure-O: Unpack the file to standard output The parameter-F is required-f:  Use the file name, remember that this parameter is the last parameter, after the file name can only be received. # tar -cf all.tar *.jpg  This command is to make all. jpg files into a package called All.tar. -C is the file name that represents the generation of a new package,-f specifies the package. # tar -rf all.tar *.gif  This command adds all the. gif files to the All.tar package. -R is meant to increase the file. # tar -uf all.tar logo.gif  This command is to update the original tar package All.tar in the logo.gif file,-U is to indicate the meaning of the update file. # tar -tf all.tar  This command is to list all the files in the All.tar package,-T is to list the meaning of the file # tar -xf all.tar  This command is to solve all the files in the All.tar package,-X is to untie the meaning of compression tar –cvf jpg.tar *.jpg   to package all JPG files in the directory into tar.jpgtar  –czf jpg.tar.gz *.jpg    After packaging all the JPG files in the directory into Jpg.tar and compressing them in gzip, generate a gzip-compressed package named jpg.tar.gztar –cjf jpg.tar.bz2 *.jpg  After packaging all the JPG files in the directory into Jpg.tar, and compressing them with bzip2, a bzip2 compressed package is generated, named Jpg.tar.bz2tar –czf jpg.tar.z *.jpg    After packaging all the JPG files in the directory into Jpg.tar, and compressing them with compress, a umcompress compressed package is generated, named Jpg.tar.zrar a jpg.rar *.jpg  rar format compression, you need to download the Rar for linuxzip jpg.zip *.jpg   zip format of compression, you need to download the zip  for linux  Decompression tar –xvf file.tar   extract  tar pack tar -xzvf file.tar.gz   Decompression tar.gztar -xjvf file.tar.bz2    Decompression  tar.bz2tar –xzvf file.tar.z     unzip the tar. zunrar e file.rar  Decompression rarunzip file.zip  Extract zip summary *.tar  with  tar –xvf  unzip * .gz  with  gzip -d or gunzip  decompression *.tar.gz and *.tgz  with  tar –xzf  decompression *.bz2  with   bzip2 -d or use bunzip2  decompression *.tar.bz2 with tar –xjf  decompression *. z  with  uncompress  unzip *.tar. z  with tar –xzf  decompression *.rar  with  unrar e decompression *.zip  with  unzip  decompression


Linux Tar Decompression Command summary

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.