how to extract file .gz code example Example 1: how to decompress gzip file in linux gunzip -k file.gz Example 2: how to read .gz file zcat logfile.gz