Solved

Un-tar-ing a tar file

Posted on 2009-07-07
10
732 Views
Last Modified: 2013-12-26
Hi,

I have a file:


client237:ExerciseTwo stevey_mac2k2$ tar zxvf phpMyAdmin-3.2.0.1-english.tar

gzip: stdin: not in gzip format
tar: Child returned status 1
tar: Error exit delayed from previous errors
client237:ExerciseTwo stevey_mac2k2$

and also in sudo

bash-3.2# tar -C zxvf phpMyAdmin-3.2.0.1-english.tar
tar: You must specify one of the `-Acdtrux' options
Try `tar --help' or `tar --usage' for more information.

Just trying to untar my phpMyAdmin file. :oS

Stephen
0
Comment
Question by:StephenMcGowan
  • 3
  • 2
  • 2
  • +2
10 Comments
 
LVL 39

Accepted Solution

by:
Adam314 earned 200 total points
ID: 24797432

tar -xvf phpMyAdmin-3.2.0.1-english.tar

Open in new window

0
 
LVL 45

Assisted Solution

by:Kdo
Kdo earned 100 total points
ID: 24797441

Try this:

  tar -xzvf phpMyAdmin-3.2.0.1-english.tar


On some versions of *tar*, the first option after the '=' sign has to be the "command".


Good Luck,
Kent
0
 
LVL 40

Assisted Solution

by:omarfarid
omarfarid earned 100 total points
ID: 24797539
no need for the z option since it seams not to be a compressed tar file, try

tar -xvf phpMyAdmin-3.2.0.1-english.tar
0
Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

 
LVL 68

Expert Comment

by:woolmilkporc
ID: 24797568
The -C option (change to directory ....) is missing the required value (the target directory)

Try

tar zxvf phpMyAdmin-3.2.0.1-english.tar -C /target/directory
0
 
LVL 68

Expert Comment

by:woolmilkporc
ID: 24797583
Sorry, copy and paste error

tar -zxvf phpMyAdmin-3.2.0.1-english.tar -C /target/directory
0
 
LVL 68

Assisted Solution

by:woolmilkporc
woolmilkporc earned 100 total points
ID: 24797599
... sticky fingers ...

tar -xvf phpMyAdmin-3.2.0.1-english.tar -C /target/directory
 
 
0
 

Author Comment

by:StephenMcGowan
ID: 24797723
my attempts..... and fails....

bash-3.2# tar -xvf phpMyAdmin-3.2.0.1-english.tar -C /Users/stevey_mac2k2/Desktop/ExerciseTwo
tar: This does not look like a tar archive
tar: Skipping to next header
tar: Read 6930 bytes from phpMyAdmin-3.2.0.1-english.tar
tar: Archive contains obsolescent base-64 headers
tar: Error exit delayed from previous errors

bash-3.2# tar -xvf phpMyAdmin-3.2.0.1-english.tar
tar: This does not look like a tar archive
tar: Skipping to next header
tar: Read 6930 bytes from phpMyAdmin-3.2.0.1-english.tar
tar: Archive contains obsolescent base-64 headers
tar: Error exit delayed from previous errors



0
 
LVL 40

Expert Comment

by:omarfarid
ID: 24797785
how this file was created / transferred? What is the exact file name ? was it a compressed file which  was renamed? try to add .gz to the file name (mv file to file.gz) then try with the original command with -zxvf
0
 

Author Comment

by:StephenMcGowan
ID: 24797915
Nevermind i've sorted it now... i downloaded the tar.gz and ran the command on that instead :)
0
 
LVL 39

Expert Comment

by:Adam314
ID: 24798995
You could also use the file command which looks at actual bytes in the file to try to determine what type of file it is.

file phpMyAdmin-3.2.0.1-english.tar

Open in new window

0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Perl Write to Specific line in a file 15 94
Write an app 10 70
retrieve nuemaric value from txt file in shell script 3 68
Matching a random pattern with one common character 2 63
Over the years I've spent many an hour playing on hardened, DMZ'd servers, with only a sub-set of the usual GNU toy's to keep me company; frequently I've needed to save and send log or data extracts from these server back to my PC, or to others, and…
In the distant past (last year) I hacked together a little toy that would allow a couple of Manager types to query, preview, and extract data from a number of MongoDB instances, to their tool of choice: Excel (http://dilbert.com/strips/comic/2007-08…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…

803 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question