LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   extract tar.gz file (https://www.linuxquestions.org/questions/linux-newbie-8/extract-tar-gz-file-501173/)

manolakis 11-13-2006 10:35 AM

extract tar.gz file
 
Hey there!!!!
Does anyone know how to extract a file with 'tar.gz' extention?
Actually i want to install this file.

Really thanks for your time

Gethyn 11-13-2006 10:43 AM

To extract a tar.gz file, you can use the command 'tar xvzf filename', or use a GUI program such as Ark. If it's a program you want to install, the method varies slightly depending on what the archive contains. Which distro are you using, and what is the program you're trying to install from the archive? There may be a better way of installing, using a package management program.

b0uncer 11-13-2006 10:45 AM

It's a compressed (.gz) archive (.tar), uncompressed and -archived with (if using GNU tar):
Code:

tar -xzf filename.tar.gz
You can do this in two steps too:
Code:

gunzip filename.tar.gz
tar -xf filename.tar

To install the content, if it's installable (like source code), read the included INSTALL and/or README and/or other doc files (which may be under doc/ or something, too). Typical installing of source code goes like (cd to the source code directory first):
Code:

./configure
make
su
#*# now give root password, or use sudo instead #*#
make install

but it might differ from that, so read INSTALL, README and other documentation first!

jschiwal 11-13-2006 10:49 AM

First make sure this tarball is in a directory where you have full permissions.
You can extract it with the command "tar xvzf <name>.tar.gz". Then cd into the extracted directory. Check for a README and an INSTALL file. Be sure to read them through. Most likely there will be a "configure" file.
If so, the normal process is:
./configure
make
su
<password>
make install

However, there may be a "make test" or an option to use with "configure" that the README file points out.
Also, often software installed this way will go into the /usr/local hierarchy. Some people prefer it go into the /usr hierarchy, and to do this use "./configure prefix=/usr" instead.


All times are GMT -5. The time now is 03:52 PM.