List the contents of tar gz file
tar command is archiving utility. Something, you can retrieve extension .tar.gz or .tar.bz2 file. How to list the contents this without extracting from command line. The syntax tar command as below: tar OPTION File_Name With OPTION : t, --list : List the contents of an archive v : Verbosely list files processed j : Filter archive through bzip2 f : filename You may reading link as below: Iptables how to How to reset password on centos 7 Bash script example List the contents of .tar.gz file To use tar command for .tar.gz as following: $ tar -tvf links-2.12.tar.gz The output of links-2.12.tar.gz file as below: -rwxr--r-- 1000/1000 1215 2001-10-05 14:03 links-2.12/mailcap.pl -rwxr-xr-- 1000/1000 4654 2015-06-28 22:13 links-2.12/rebuild -rw-r--r-- 1000/1000 461 2003-05-06 01:10 links-2.12/links_16x16_1.xpm -rw-r--r-- 1000/1000 2410 2003-05-06 01:10 links-2.12/links_32x32.xpm -rw-r--r-- 1000/1000 3847 2005-03-01 00:16 links-2.12/links-48x48.xpm -