Posted by: Anonymous Coward
on September 11, 2005 09:44 AM
>Typically you use the bzip2 utility to create bz >files and gzip to create gz. The fundamental >difference is in the compression algorithm used >by bzip2, which results in considerably smaller >files. The downside is that bzip2 eats up more >memory.
Not only more memory, a lot of more time.
>Unlike zip, which offers compression and >archiving functionality, tar is capable of >archiving only. This means that after you create >a tarball, its size is the same as the cumulative > size of the individual files. To reduce the size > of a tarball, you must compress it by using >either gzip or bzip2:
remarks
Posted by: Anonymous Coward on September 11, 2005 09:44 AM>files and gzip to create gz. The fundamental
>difference is in the compression algorithm used
>by bzip2, which results in considerably smaller
>files. The downside is that bzip2 eats up more
>memory.
Not only more memory, a lot of more time.
>Unlike zip, which offers compression and
>archiving functionality, tar is capable of
>archiving only. This means that after you create
>a tarball, its size is the same as the cumulative
> size of the individual files. To reduce the size
> of a tarball, you must compress it by using
>either gzip or bzip2:
>tar -cf archived.tar file1 file2 file3
>gzip archived.tar
For an explanation to newcomers, I think you correctly divide the tar and gzip steps, and avoid the unportable tar -zcf
>How do you extracting files from a compressed
>tarball? Use tar zxvf archived.tar.gz to extract
>all the files from a gzip-compressed tarball.
But why introduce -z here?
I would say
$ gunzip archived.tar.gz
$ tar -xf archived.tar
and then explain about the GNU-tar-only z and j options/shortcuts.
I also tell new users to use the v (verbose) switch, in order to get the feel of what is being added or extracted.
#