How can I extract a single file or folder from a large tar.gz archive?

Maxoq

Well-known member
Registered
Joined
Feb 25, 2015
Messages
520
Points
28
Hi everyone,

I have large tar archive file (.tar.gz) on my VPS server and it was compressed by my previous hosting prorvider, they sent me the link to download, now I need to unzip it.
Can someone help me to extract particular this type of file?

Thanks,
Max
 

24x7CSM

Well-known member
Registered
Joined
Sep 27, 2016
Messages
263
Points
28
You can not extract a particular file from .tar.gz .. its has to be extracted completely in order to get that single file you are looking for.

in order to extract the file , use the command

tar -zxvf filename.tar.gz
 

Maxoq

Well-known member
Registered
Joined
Feb 25, 2015
Messages
520
Points
28
Maxoq
What is -zxvf in your command? why do I need to include it?
One question more, tar command is the default command from Linux and I don't need to install before using?
 

LJSHost

Well-known member
Hosting Provider
Registered
Joined
Jul 5, 2016
Messages
1,031
Points
63
Alternatively you could download the file to your PC and extract what you need using 7Zip or any good zip program for mac or windows.
Saves unzipping a large archive on your VPS to grab a single item.
 

LJSHost

Well-known member
Hosting Provider
Registered
Joined
Jul 5, 2016
Messages
1,031
Points
63
Yes Tar should be installed as part of the basic system utilities.

They are the options for the Tar command.


- f, is the file
- v, verbose output
- z, gzip
- x Extract
 
Newer Threads
Replies
9
Views
4,539
Replies
2
Views
6,114
Replies
12
Views
4,871
Latest Threads
Replies
1
Views
25
Replies
0
Views
180
Replies
1
Views
39
Replies
2
Views
81
Recommended Threads
Replies
3
Views
3,307
Replies
5
Views
3,360
Replies
3
Views
3,200
Replies
7
Views
5,867

Latest postsNew threads

Latest Hosting OffersNew Reviews

Sponsors

Tag Cloud

You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an alternative browser.

Top