Decompressing the archive

To decompress the archive, use the compressor's corresponding utility.

In the case of a .gz or .tgz file, use gunzip:

gunzip my_archive.tar.gz

or:

gunzip my_archive.tgz

These commands decompress the file, resulting in my_archive.tar. You can also use tar with the -z option to extract from the archive without decompressing it first:

tar -xzf  my_archive.tgz