Tarfile .bz2

Jordan jordan.taylor2 at gmail.com
Mon Dec 11 20:32:58 EST 2006


So that would explain why a tar.bz2 archive can't be appended to
wouldn't it...  And also explain why winrar was so slow to open it (not
something I mentioned before, but definitely noticed).  I had wondered
what it was that made bz2 so much better at compression than zip and
rar.  Not really on topic anymore but what's the method for tar.gz? And
even more off the topic, does anyone know a good lossless compression
method for images (mainly .jpg and .png)?

Cheers,
Jordan


Wolfgang Draxinger wrote:
> Jordan wrote:
>
> > When using python to create a tar.bz2 archive, and then using
> > winrar to open the archive, it can't tell what the compressed
> > size of each
> > individual file in the archive is.  Is this an issue with
> > winrar or is there something that needs to be set when making
> > the archive that isn't there by default.
>
> When compressing a tar archive all files in the archive are
> compressed as a whole, i.e. you can only specify a compression
> ration for the whole archive and not just for a single file.
>
> Technically a tar.bz2 is actually a aggregation of multiple files
> into a single tar file, which is then compressed.
>
> This is different to e.g. PKZip in which each file is compressed
> individually and the compressed files are then merged into an
> archive.
>
> The first method has better compression ratio, since redundancies
> among files are compressed, too, whereas the latter is better if
> you need random access to the individual files.
>
> Wolfgang Draxinger
> --
> E-Mail address works, Jabber: hexarith at jabber.org, ICQ: 134682867




More information about the Python-list mailing list