LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
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!

Notices


Reply
  Search this Thread
Old 06-12-2009, 07:22 AM   #1
rajivdp
Member
 
Registered: Oct 2008
Posts: 34

Rep: Reputation: 17
Problem:zip: file_name.tar.gz: invalid compressed data--crc error.


Hi All

I had taken a backup of workspace with help of "tar" and "gz" command and transfered the file to other machine with "scp" command.i tried to extract the file with following command in the other machine


$gzip -d file_name.tar.gz

I recived the following error

zip: file_name.tar.gz: invalid compressed data--crc error

Problem:I dont have original source file.

Thanks and Regards
Rajiv
 
Old 06-12-2009, 07:46 AM   #2
Wim Sturkenboom
Senior Member
 
Registered: Jan 2005
Location: Roodepoort, South Africa
Distribution: Slackware 10.1/10.2/12, Ubuntu 12.04, Crunchbang Statler
Posts: 3,786

Rep: Reputation: 282Reputation: 282Reputation: 282
Did you try 'gunzip' command?
 
Old 06-12-2009, 09:52 AM   #3
rajivdp
Member
 
Registered: Oct 2008
Posts: 34

Original Poster
Rep: Reputation: 17
Yes, i tried with "gunzip" command too.It fails again with same error.

Thanks and Regards
Rajiv
 
Old 06-12-2009, 10:02 AM   #4
jdkaye
LQ Guru
 
Registered: Dec 2008
Location: Westgate-on-Sea, Kent, UK
Distribution: Debian Testing Amd64
Posts: 5,464

Rep: Reputation: Disabled
Quote:
Originally Posted by rajivdp View Post
Hi All

I had taken a backup of workspace with help of "tar" and "gz" command and transfered the file to other machine with "scp" command.i tried to extract the file with following command in the other machine


$gzip -d file_name.tar.gz

I recived the following error

zip: file_name.tar.gz: invalid compressed data--crc error

Problem:I dont have original source file.

Thanks and Regards
Rajiv
If this really is a tarball then I always use the "tar" command and not the gzip command to unpack the file. Something like
Code:
tar zxvf file_name.tar.gz
should work.
cheers,
jdk
 
Old 06-15-2009, 02:41 AM   #5
rajivdp
Member
 
Registered: Oct 2008
Posts: 34

Original Poster
Rep: Reputation: 17
Smile

Thanks Jdkaye.

tar zxvf file_name.tar.gz

extracts most of the files before it fails and got back all my important files.

Thanks and Regards
Rajiv
 
Old 06-15-2009, 03:53 AM   #6
jdkaye
LQ Guru
 
Registered: Dec 2008
Location: Westgate-on-Sea, Kent, UK
Distribution: Debian Testing Amd64
Posts: 5,464

Rep: Reputation: Disabled
Quote:
Originally Posted by rajivdp View Post
Thanks Jdkaye.

tar zxvf file_name.tar.gz

extracts most of the files before it fails and got back all my important files.

Thanks and Regards
Rajiv
How does it fail? Can you post the error message?
cheers,
jdk
 
Old 06-15-2009, 09:21 AM   #7
barunparichha
Member
 
Registered: Jun 2006
Location: Bangalore,india
Distribution: Linux(Redhat,fedora,suse,ubantu), Solaris (s8/s9/s10/nevada/open-solaris)
Posts: 285

Rep: Reputation: 32
check the compression type before uncompressing.
The file command will help you.

file <compressed-file>
 
Old 06-15-2009, 10:13 AM   #8
rajivdp
Member
 
Registered: Oct 2008
Posts: 34

Original Poster
Rep: Reputation: 17
JDK

Quote:
How does it fail? Can you post the error message?
Error message:

gzip: stdin: invalid compressed data--crc error
tar: Child returned status 1
tar: Error exit delayed from previous error


Thanks and Regards
Rajiv
 
Old 06-15-2009, 10:31 AM   #9
jdkaye
LQ Guru
 
Registered: Dec 2008
Location: Westgate-on-Sea, Kent, UK
Distribution: Debian Testing Amd64
Posts: 5,464

Rep: Reputation: Disabled
Quote:
Originally Posted by rajivdp View Post
JDK



Error message:

gzip: stdin: invalid compressed data--crc error
tar: Child returned status 1
tar: Error exit delayed from previous error


Thanks and Regards
Rajiv
Hi Rajiv,
Looks like the tarball is corrupted in some way. At least you got the important files.
cheers,
jdk
 
  


Reply


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
gzip: stdin: invalid compressed data--format violated ftp ascii transfer sridhar_dct3 Linux - Software 10 07-28-2012 03:25 PM
gzlib: stdin: invalid compressed data -crc error pashford Linux - General 4 04-29-2008 08:21 AM
FC 6: gunzip: stdin: invalid compressed data--format violated jnonaka Linux - Newbie 14 03-23-2007 03:24 PM
invalid compressed data error Seyfert Linux - Newbie 1 04-26-2006 04:47 PM
invalid compressed data crc--error aurelio26 Linux - Newbie 3 10-08-2004 03:53 PM


All times are GMT -5. The time now is 06:57 PM.

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