Review your favorite Linux distribution.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 03-06-2010, 04:55 AM   #1
Danyal Raja
LQ Newbie
Registered: Mar 2010
Posts: 6

Rep: Reputation: 0
Unhappy cant unpack tar.gz

m new to linux and working in php. i have downloaded zend guard but there is problem in unpacking tar,gz... any 1 plz help

Last edited by Danyal Raja; 03-06-2010 at 04:57 AM.
Old 03-06-2010, 05:58 AM   #2
Senior Member
Registered: Jan 2009
Location: vijayawada, India
Distribution: openSUSE 11.2, Ubuntu 9.0.4
Posts: 1,155
Blog Entries: 12

Rep: Reputation: 92
Install Gunzip to extract *.gz files
install bunzip to extract *.bz files

By default, fedora already have them!
Old 03-06-2010, 06:00 AM   #3
LQ 5k Club
Registered: May 2001
Location: Belgium
Distribution: Arch
Posts: 8,528

Rep: Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899
You can use tar
tar -zxvf file.tar.gz
Old 03-08-2010, 08:23 AM   #4
Registered: Nov 2002
Location: Kent, England
Distribution: Debian Testing
Posts: 19,192
Blog Entries: 4

Rep: Reputation: 470Reputation: 470Reputation: 470Reputation: 470Reputation: 470
Moved: This thread is more suitable in Linux-Newbie and has been moved accordingly to help your thread/question get the exposure it deserves.
Old 03-08-2010, 12:11 PM   #5
LQ Newbie
Registered: Mar 2010
Posts: 7

Rep: Reputation: 1
tar -zxvf file.tar.gz -C path/to/location

if you want to extract to specific location
1 members found this post helpful.
Old 03-08-2010, 12:37 PM   #6
Registered: Jul 2007
Location: Scunthorpe, UK
Distribution: Ubuntu 8.10; Gentoo; Debian Lenny
Posts: 961

Rep: Reputation: 69
Perhaps you could tell us what the exact problem is. An error message perhaps; otherwise you're just going to get commands thrown at you where you may have a missing dependency, you may not be specifying the right path, or whatever.

For reference, take a look at the man page for tar; man pages (Manual Pages) are the first page you want to be looking for help on a specific command, and are accessed by
$ man <command>
Old 03-08-2010, 04:56 PM   #7
LQ Guru
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 18,903

Rep: Reputation: 4262Reputation: 4262Reputation: 4262Reputation: 4262Reputation: 4262Reputation: 4262Reputation: 4262Reputation: 4262Reputation: 4262Reputation: 4262Reputation: 4262
Originally Posted by Danyal Raja View Post
m new to linux and working in php. i have downloaded zend guard but there is problem in unpacking tar,gz... any 1 plz help
Spell out your words, and write clearly. It also would help to give version/distro of Linux, etc.

If you tried to Google this, you would have found an answer very quickly. To ungzip something, it's "gzip -d <filename>". To untar it, "tar xvf <filename>". Since you have a Gzipped TAR file, do one, then the other. Or, as others have said, "tar xvfz <filename>". Reading the man pages on tar and gzip would help, too.
Old 03-08-2010, 05:04 PM   #8
LQ 5k Club
Registered: Sep 2009
Posts: 6,443
Blog Entries: 3

Rep: Reputation: 721Reputation: 721Reputation: 721Reputation: 721Reputation: 721Reputation: 721Reputation: 721
Or just use:

tar xf filename
Newer versions of tar automatically detect if the archive is compressed with gzip or bzip2 and automatically executes gunzip or bunzip before extracting.

Remember, the tar format just archives a directory tree into a single file, it does not compress the data. Separate compression tools, like gzip or bzip2, must be run on the archive if you want it to be compressed. This is unlike Microsoft's zip archive format, which has built-in compression.

Last edited by MTK358; 03-08-2010 at 05:08 PM.
Old 03-09-2010, 01:12 AM   #9
Danyal Raja
LQ Newbie
Registered: Mar 2010
Posts: 6

Original Poster
Rep: Reputation: 0
well thanx to all.... my problem is solved


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
tar.gz will not unpack werfer Linux - General 5 06-30-2006 06:42 PM
how to unpack .tar? g-string 3 Debian 8 11-29-2004 08:01 AM
what do i do after i unpack the tar.gz sanjaya Linux - Software 1 02-11-2004 07:58 PM
tar gz files unpack attika Linux - General 1 08-06-2002 07:04 PM
How to unpack a .tar.gz2 file? ReSync Linux - Newbie 1 06-18-2002 06:43 AM

All times are GMT -5. The time now is 02:21 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration