6

In 7-zip file manager I created a tar file (with many subdirectories and files inside). I uploaded this file to the Debian server but can't extract:

tar -xvfz files.tar
gzip: stdin: not in gzip format
tar: Child returned status 1
tar: Error is not recoverable: exiting now

I also tried tar -xvf userpics.tar but then happends just nothing.

Any ideas how to extract this file?

user1406271
  • 1,071
  • 4
  • 14
  • 20

3 Answers3

13

It is a tar file, not a .tar.gz

-z is for gzip

try:

tar xvf files.tar
mulaz
  • 10,682
  • 1
  • 31
  • 37
  • I tried it but nothing happends. No error, nothing and the file stays as it is. – user1406271 May 23 '12 at 15:32
  • if you type "file files.tar" does it say it's a tar file? – mulaz May 23 '12 at 15:33
  • files.tar: data – user1406271 May 23 '12 at 15:35
  • 1
    It is not a .tar file then. Try installing p7zip on your server and extracting the file with it. If it was a tar file it should say: files.tar: POSIX tar archive (GNU) – mulaz May 23 '12 at 15:37
  • Strange. What is the reason it's not a tar file? I have done the same many times before (but uploading from a different computer) and it was working just fine. – user1406271 May 23 '12 at 15:39
  • I have no idea, maybe it got corrupted on transfer or something simmilar. You can try to transfer it back to your pc, and extracting it there to verify. Or just try taring the files again and sending them again. – mulaz May 23 '12 at 15:41
1

tar xvf files.tar

As it's not a gzip file, you don't need the z parameter.

smottt
  • 111
  • 3
bandito
  • 136
  • 2
0

Chances are its not a tar file. Do sudo apt-get install p7zip instead.

gfountis
  • 1
  • 2