CentOS tar compression and decompression commands Daquan

Source: Internet
Author: User
Tags gz file centos server

The management of the CentOS server often do some regular operation of the file, in addition to FTP to understand the necessary file operation under SSH command that is also essential, the following excerpt some common file operation commands: file operation:Disk remaining Space # # #find/-name Xxx-print # # # # #查找xxx文件 # # # compression and decompression:Tar xvf wordpress.tar       ### #解压tar格式的文件 # # #tar-TVF myfile.tar       #### View files that are included in the tar file  ### #tar CF Toole.tar tool       ### #把tool目录打包为toole. tar file # # # #tar CFZ xwyme.tar.gz tool      #### The tool directory is packaged and compressed into a xwyme.tar.gz file because. tar files are almost uncompressed, and the. tar.gz file of Mt is extracted to a. tar file almost 10mb ### #tar jcvf/var/bak/ www.tar.bz2/var/www/      ### #创建. tar.bz2 file, high compression rate # # #tar XJF www.tar.bz2        # # # #解压tar. bz2 Format # # #gzip-D ge.tar.gz       ### #解压. tar.gz files to. tar Files # # # #unzip Phpbb.zip       ### #解压zip文件, it's a bit of a hassle to compress a. tar.gz formatted file under Windows #### bunzip2 file1.bz2       ### #解压一个叫做 ' file1.bz2′ Files # # # #bzip2 file1       ### #压缩一个叫做 ' file1′ files # # # #gunzip file1.gz    & nbsp  ### #解压一个叫做 ' file1.gz ' Files # # # #gzip file1       ### #压缩一个叫做 ' file1′ files # # # # #gzip-9 File1  & nbsp    ### #最大程度压缩 ## # #rar a file1.rar test_file       ### #创建一个叫做 ' File1.rar ' package # # # #rar a file1.rar file1 file2 dir1 &nbsp ;     ### #同时压缩 ' file1′, ' file2′ and directory ' dir1′### #rar x file1.rar       ### #解压rar包 # # # # #unr AR x file1.rar       ### #解压rar包 # # #tar-CVF archive.tar file1       ### #创建一个非压缩的 t arball### #tar-cvf archive.tar file1 file2 dir1       ### #创建一个包含了 ' file1′, ' file2′ ' and ' dir1′ ' Files # # # #t AR-TF Archive.tar       ### #显示一个包中的内容 # # #tar-xvf archive.tar       ### #释放一个包 # # # #tar-XVF archive.tar-c/tmp       ### #将压缩包释放到/tmp directory under # # #tar-CVFJ archive.tar.bz2 dir1  &nbsp ;    ### #创建一个bzip2格式的压缩包 # # #tar-xvfj archive.tar.bz2       ### #解压一个bzip2格式的压缩包 # # # #tar- CVFZ archive.tar.gz dir1       ### #创建一个gzip格式的压缩包 # # # #tar-XVFZ archive.tar.gz      & nbsp;### #解压一个gzip格式的压缩包 # # # #zip filE1.zip file1       ### #创建一个zip格式的压缩包 # # #zip-R file1.zip file1 file2 dir1       ## # #将几个文件和目录同时压缩成一个zip格式的压缩包 # # #unzip file1.zip       ### #解压一个zip格式压缩包 ####  Original:/http Www.centoscn.com/CentOS/help/2013/0725/496.html Recommendation: http://man.linuxde.net/Command Daquan website

CentOS tar compression and decompression commands Daquan

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.