+5 votes
181 views
by (40.6k points)
More and more tar files using xz LZMA2 format based on compression instead of traditional bzip2 (bz2) compression. Kernel.org actually did an afternoon "Goodbye bzip2" announcement, 27th Dec. 2013, indicating the kernel sources from this point would be released in tar.gz and tar.xz format - and the Home of the website which is It is offered directly tar.xz.

Is there any specific reason that explains why this happens and what is the relevance of gzip In this context?

1 Answer

+3 votes
by (40.6k points)

For distributing files on the Internet, the following things are usually a priority:

  • Compression ratio (ie, how small the compressor makes data);
  • Decompression time (CPU requirements);
  • Decompression memory requirements; and
  • Compatibility (how extensive the decompression program)
  • Compression memory & CPU requirements are not very important, because you can use a big fast machine for that, and you just have to do it once.
  • Compared with bzip2, xz has better compression ratio and shorter decompression (better). However, it requires more memory to decompress [1] and is slightly less widespread.
  • So both xz gzip format files are published, allowing you to choose:
  • You need to decompress on a machine with very limited memory (<128 MB): gzip. Considering not very likely that when you talk about kernel sources.
  • You need to decompress minimal tools available: gzip
  • Do you want to save download time and bandwidth: xz
  • There is really a combination of factors that lead to look realistic bzip2. So be eliminated.
  • I looked at comparisons compression to post blog. Do not attempt to replicate the results, and I suspect that something has changed (mostly, I hope xz has improved, as is the most recent.)
  • 1: this depends on counting. For example, the file size, xz -3 -9 bzip is about. Then xz uses less memory to decompress. But xz -9 bzip used more than -9.

6.5k questions

8.2k answers

191 comments

71 users

Please leave a comment if the solution works or not.
(with device model) [X]Close
Ask a Question
Welcome to Wikiwhy Q&A, where you can ask questions and receive answers from other members of the community.

Categories

...