Comparison of gzip, Bzip2, and zip compression rates in Linux

Source: Internet
Author: User

There are many compression tools under linux, and the commonly used format is tar.gz, tar.bz2, zip, etc.

A simple comparison:

Tar-zcvf etc.tar.gz/etctar-jcvf etc.tar.bz2/etczip-ry etc.zip/etc

Note: you must add two options to the zip command.

-R indicates recursive directory. Otherwise, only one empty directory is pressed.

-Y indicates that the symbolic link is maintained, and the file to which the symbolic link is directed does not need to be pressed in.

Comparison results:

[Root @ centos6-244-desktop TMP] # ll-h total usage 25m-rw-r -- r --. 1 Root 7.1 m 11:13 October 11 etc.tar.bz2-RW-r --. 1 Root 8.2 m 11:13 October 11 etc.tar.gz-RW-r --. 1 Root 8.8 M October 11 11:13 etc.zip

You can see:

Compression rate Bzip2> gzip> zip

Zipping is more common, and now Windows software winrar,7zipis also very good for tar.gz support. Recommended use of tar.gz, Bzip2 requires more CPU

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.