Operating System - HP-UX
1819791 Members
3155 Online
109607 Solutions
New Discussion юеВ

Gzip decompress a file error.

 
ckchai
Frequent Advisor

Gzip decompress a file error.

Hi,

I'm ftp some file from a windows system to Hp-Unix 11.00.

I used the Binary mode.

After the file transfered to HP-Unix system, I do a uncompressed. But I have error doing this.

command and error message on screen :-

fme6:/users/mpeda/INOTFE> cd data
fme6:/users/mpeda/INOTFE/data> ll
total 2830
-rw-r----- 1 mpeda users 277498 Mar 13 11:15 CP_AC548110.00_01_2_200602090339.gz
-rw-r----- 1 mpeda users 1171398 Mar 13 09:32 RD_AC550207.00_25_1_200602261338.gz
fme6:/users/mpeda/INOTFE/data> gzip -d CP_AC548110.00_01_2_200602090339.gz
incomplete distance tree

gzip: CP_AC548110.00_01_2_200602090339.gz: invalid compressed data--format violated
fme6:/users/mpeda/INOTFE/data> mv CP_AC548110.00_01_2_200602090339.gz cp.gz
fme6:/users/mpeda/INOTFE/data> ll
total 2830
-rw-r----- 1 mpeda users 1171398 Mar 13 09:32 RD_AC550207.00_25_1_200602261338.gz
-rw-r----- 1 mpeda users 277498 Mar 13 11:15 cp.gz
fme6:/users/mpeda/INOTFE/data> gzip -d cp.gz
incomplete distance tree

gzip: cp.gz: invalid compressed data--format violated
fme6:/users/mpeda/INOTFE/data> ll
total 4944
17 REPLIES 17
Arunvijai_4
Honored Contributor

Re: Gzip decompress a file error.

Hello,

After you do the transfer, make sure the "cksum" command gives the similat output on both servers.

-Arun
"A ship in the harbor is safe, but that is not what ships are built for"
Muthukumar_5
Honored Contributor

Re: Gzip decompress a file error.

Try to transfer the file again. May be a problem with transfer.

Another way is try to the same step in server side. Is it working?

--
Muthu
Easy to suggest when don't know about the problem!
Senthil Kumar .A_1
Honored Contributor

Re: Gzip decompress a file error.

Hi,

I don't you get a different result with "gunzip" command. Still have you tried the following.

#gunzip cp.gz


Regards,
Senthil Kumar .A
Let your effort be such, the very words to define it, by a layman - would sound like a "POETRY" ;)
ckchai
Frequent Advisor

Re: Gzip decompress a file error.

Hi,
I cannot do cksum on the Windows server.

Anyway I did try "gunzip" command.

I'm getting the same error message.

It is because of the *.gz files already have problem when FTP to the UNIX server?

regards,
ck chai
Senthil Kumar .A_1
Honored Contributor

Re: Gzip decompress a file error.

Hi,

Are you able to decompress those files in windows box, using "winzip" application.

Regards,
Senthil Kumar .A
Let your effort be such, the very words to define it, by a layman - would sound like a "POETRY" ;)
Arunvijai_4
Honored Contributor

Re: Gzip decompress a file error.

Hello,

I hope you have downloaded .gz files on Windows and trying to transfer. First of all, check you can open the file in windows without any error. You can try to open with Winzip or Winrar.

I suspect, your download is corrupt.

-Arun
"A ship in the harbor is safe, but that is not what ships are built for"
Muthukumar_5
Honored Contributor

Re: Gzip decompress a file error.

Try to transfer files or directories without .gz format. (As whole directory to hp-ux) if it is urgent.

Or try to transfer the same file to other platform like linux and check it.

--
Muthu
Easy to suggest when don't know about the problem!
ckchai
Frequent Advisor

Re: Gzip decompress a file error.

I'm trying to open the *.gz file on the Windows server.

I have an error :-

Invalid compressed data - Unable to inflate.


I'm investigating the problem on the source server that transfer the files to my Hp-unix server.

Thanks.
Arunvijai_4
Honored Contributor

Re: Gzip decompress a file error.

Hello,

Invalid compressed data - Unable to inflate.

This means that the file is corrupted. You need to re-download it again.

-Arun
"A ship in the harbor is safe, but that is not what ships are built for"
Yogeeraj_1
Honored Contributor

Re: Gzip decompress a file error.

hi,

make sure again that you have transferred the file in binary mode.

you may also user unzip for compression and decompression in case this does not work

hope this helps!

kind regards
yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)
Muthukumar_5
Honored Contributor

Re: Gzip decompress a file error.

The problem is with the .gz file. try to download it again.

However, google search with "Invalid compressed data - Unable to inflate" says that problem is with winzip or winrar too :(

--
Muthu



Easy to suggest when don't know about the problem!
Senthil Kumar .A_1
Honored Contributor

Re: Gzip decompress a file error.

Hi,

I was able to open *.gz files in the past with the "winzip" app without any errors. If it shoots out error it means, either there was a download problem or download format was wrong. Make sure when you are downloading it from ftp server, *.gz is downloaded in bin format. Test it using "winzip" and then trasfer it to the uniz box where you want it to be inflated.

regards,
Senthil Kumar .A
Let your effort be such, the very words to define it, by a layman - would sound like a "POETRY" ;)
Peter Godron
Honored Contributor

Re: Gzip decompress a file error.

Hi,
I believe the problem is a corrupt gz file.

Please recreate the gz file on your windows box, then ftp binary format and unzip on hpux box.

This is suggested by the fact that you can not unzip the original gz file on the original windows box.
Kent Ostby
Honored Contributor

Re: Gzip decompress a file error.

If you are using FTP to transfer the file, make sure you are in binary mode.

To turn binary mode on, type "bin" at the FTP prompt after the connection is made.

Make sure the sizes match on the two systems and/or the intermediate system ifyou have one.

If you aren't using FTP, please post the commands you are using.

"Well, actually, she is a rocket scientist" -- Steve Martin in "Roxanne"
Peter Godron
Honored Contributor

Re: Gzip decompress a file error.

Hi,
any luck with my suggestion to re-creating the zip file on Windows and trying to unzip it on the hp platform?
Liudvikas Bukys
New Member

Re: Gzip decompress a file error.

Sorry, this repeats the most-likely possibilities that others are suggesting also:

1. Most likely is an FTP without BINARY mode. You already ruled that out.

2. Is it possible that the Windows file is not a .gz but a .zip? In that case you'd need to use a free unzip program and not gunzip. They are similar but not the same.

3. Other errors such as disk-full or other file corruption would explain it too. In which case the answers is to re-transmit or re-create at its origin.

If this is critical data for which you have no other source, partial or full recovery is quite difficult but not impossible. Post a reply if that is the unfortunate situation you are in and I'll make suggestions.
ckchai
Frequent Advisor

Re: Gzip decompress a file error.

Problem solved.
It is the source files corrupted.

I just need to resent the files.

Thanks.