Unzip

Hi All,

I am having an error with a zip . It is showing me the below error. I tried using

zip 

and

jar

command all show me the same error. Not sure what is this error and why this is coming any help ?

>>>  jar -xvf 99999_zpd.zip
extracted: 100793_ipd0000.001.gz
extracted: 100793_ipd0001.001.gz
extracted: 100793_ipd0002.001.gz
extracted: 100793_ipd0003.001.gz
extracted: 100793_ipd0004.001.gz
extracted: 100793_ipd0005.001.gz
extracted: 999999_ipd0006.001.gz
extracted: 999999_ipd0007.001.gz
extracted: 999999_ipd0008.001.gz
extracted: 999999_ipd0009.001.gz
extracted: 999999_ipd0010.001.gz
extracted: 999999_ipd0011.001.gz
extracted: 999999_ipd0012.001.gz
extracted: 999999_ipd0013.001.gz
extracted: 999999_ipd0014.001.gz
extracted: 999999_ipd0015.001.gz
extracted: 999999_ipd0016.001.gz
extracted: 999999_ipd0017.001.gz
java.util.zip.ZipException: unexpected EOF
        at java.util.zip.ZipInputStream.read(ZipInputStream.java:213)
        at java.util.zip.ZipInputStream.closeEntry(ZipInputStream.java:139)
        at sun.tools.jar.Main.extractFile(Main.java:961)
        at sun.tools.jar.Main.extract(Main.java:877)
        at sun.tools.jar.Main.run(Main.java:263)
        at sun.tools.jar.Main.main(Main.java:1177) 

>> gunzip 999999_ipd0018.001.gz
gunzip: 99999_ipd0018.001.gz: unexpected end of file

>>  unzip -l 99999_zpd.zip
Archive:  99999_zpd.zip
  End-of-central-directory signature not found.  Either this file is not
  a zipfile, or it constitutes one disk of a multi-part archive.  In the
  latter case the central directory and zipfile comment will be found on
  the last disk(s) of this archive.
unzip:  cannot find zipfile directory in one of 99999_zpd.zip or
        99999_zpd.zip.zip, and cannot find 99999_zpd.zip.ZIP, period.


unzip 99999_zpd.zip
Archive:  99999_zpd.zip
  End-of-central-directory signature not found.  Either this file is not
  a zipfile, or it constitutes one disk of a multi-part archive.  In the
  latter case the central directory and zipfile comment will be found on
  the last disk(s) of this archive.
unzip:  cannot find zipfile directory in one of 99999_zpd.zip or
        99999_zpd.zip.zip, and cannot find 99999_zpd.zip.ZIP, period.

"Unexpected EOF" means the file ended before it should have, like whatever uploaded the file aborted halfway through.

"999999_ipd0018.001.gz" is probably corrupt or just plain empty. You'll notice jar printed every filename leading up to this one, but not this one. That's because jar didn't succeed in extracting this file. I suppose it began extracting it, hit end-of-file (EOF) and quit.

1 Like

Thanks 999999_ipd0018.001.gz is having data. I found another interesting thing

Step 1 : I did

gunzip 99999_ipd0018.001.gz

in one window

Step 2: Then I did

tail -f 99999_ipd0018.001.gz

on other window

step 1 terminated with the error . but step 2 is keeping on running it is running for almost 5 hours and all I see is all data is repeating. I think the file is corrupted. Is there any way to see the data in the file ?

Thanks
Arun

If there is, you'll have discovered a revolutionary new form of data compression where you can throw away half a zip file and still get its contents back.

I'm not sure what you're doing by trying to read from a binary .gz file with tail, neither gunzip nor tail work that way.