java.util.zip.ZipException: error in opening zip file

I already have a working version of 5.3.2 on my MAC, however i want to set up a new version on my external SSD where there is plenty of space. However the new copy failed to start. The logger error is:

[2018-03-15T15:23:04,800][WARN ][o.e.b.ElasticsearchUncaughtExceptionHandler] [] uncaught exception in thread [main]

org.elasticsearch.bootstrap.StartupException: org.elasticsearch.bootstrap.BootstrapException: java.util.zip.ZipException: error in opening zip file
at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:127) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.Elasticsearch.execute(Elasticsearch.java:114) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.cli.EnvironmentAwareCommand.execute(EnvironmentAwareCommand.java:58) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:122) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.cli.Command.main(Command.java:88) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:91) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:84) ~[elasticsearch-5.3.2.jar:5.3.2]
Caused by: org.elasticsearch.bootstrap.BootstrapException: java.util.zip.ZipException: error in opening zip file
at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:232) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:360) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:123) ~[elasticsearch-5.3.2.jar:5.3.2]
... 6 more
Caused by: java.util.zip.ZipException: error in opening zip file
at java.util.zip.ZipFile.open(Native Method) ~[?:1.8.0_101]
at java.util.zip.ZipFile.(ZipFile.java:219) ~[?:1.8.0_101]
at java.util.zip.ZipFile.(ZipFile.java:149) ~[?:1.8.0_101]
at java.util.jar.JarFile.(JarFile.java:166) ~[?:1.8.0_101]
at java.util.jar.JarFile.(JarFile.java:103) ~[?:1.8.0_101]
at org.elasticsearch.bootstrap.JarHell.checkJarHell(JarHell.java:175) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.JarHell.checkJarHell(JarHell.java:88) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:230) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:360) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:123) ~[elasticsearch-5.3.2.jar:5.3.2]
... 6 more
[2018-03-15T15:29:25,953][WARN ][o.e.b.ElasticsearchUncaughtExceptionHandler] [] uncaught exception in thread [main]
org.elasticsearch.bootstrap.StartupException: org.elasticsearch.bootstrap.BootstrapException: java.util.zip.ZipException: error in opening zip file
at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:127) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.Elasticsearch.execute(Elasticsearch.java:114) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.cli.EnvironmentAwareCommand.execute(EnvironmentAwareCommand.java:58) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:122) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.cli.Command.main(Command.java:88) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:91) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:84) ~[elasticsearch-5.3.2.jar:5.3.2]
Caused by: org.elasticsearch.bootstrap.BootstrapException: java.util.zip.ZipException: error in opening zip file
at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:232) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:360) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:123) ~[elasticsearch-5.3.2.jar:5.3.2]
... 6 more
Caused by: java.util.zip.ZipException: error in opening zip file
at java.util.zip.ZipFile.open(Native Method) ~[?:1.8.0_101]
at java.util.zip.ZipFile.(ZipFile.java:219) ~[?:1.8.0_101]
at java.util.zip.ZipFile.(ZipFile.java:149) ~[?:1.8.0_101]
at java.util.jar.JarFile.(JarFile.java:166) ~[?:1.8.0_101]
at java.util.jar.JarFile.(JarFile.java:103) ~[?:1.8.0_101]
at org.elasticsearch.bootstrap.JarHell.checkJarHell(JarHell.java:175) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.JarHell.checkJarHell(JarHell.java:88) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:230) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:360) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:123) ~[elasticsearch-5.3.2.jar:5.3.2]
... 6 more

I did the following:

  1. I downloaded the elasticsearch tar file for version 5.3.2 onto an external SSD on my MAC
  2. I double clicked it to unzip
  3. I went into the bin directory and typed: ./elasticsearch from terminal

Any help most appreciated

Are you sure the extraction completed successfully? This looks like one of the jar files is corrupt, which might happen if the extraction was interrupted.

I'll re- download the file and try again.

OK. I downloaded the zip file this time, which resulted in exactly the same error. Download was taken from here (https://www.elastic.co/downloads/past-releases/elasticsearch-5-3-2)

the error in the log file reads:

[2018-03-15T19:14:53,580][WARN ][o.e.b.ElasticsearchUncaughtExceptionHandler] [] uncaught exception in thread [main]
org.elasticsearch.bootstrap.StartupException: org.elasticsearch.bootstrap.BootstrapException: java.util.zip.ZipException: error in opening zip file
at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:127) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.Elasticsearch.execute(Elasticsearch.java:114) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.cli.EnvironmentAwareCommand.execute(EnvironmentAwareCommand.java:58) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:122) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.cli.Command.main(Command.java:88) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:91) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:84) ~[elasticsearch-5.3.2.jar:5.3.2]
Caused by: org.elasticsearch.bootstrap.BootstrapException: java.util.zip.ZipException: error in opening zip file
at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:232) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:360) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:123) ~[elasticsearch-5.3.2.jar:5.3.2]
... 6 more
Caused by: java.util.zip.ZipException: error in opening zip file
at java.util.zip.ZipFile.open(Native Method) ~[?:1.8.0_101]
at java.util.zip.ZipFile.(ZipFile.java:219) ~[?:1.8.0_101]
at java.util.zip.ZipFile.(ZipFile.java:149) ~[?:1.8.0_101]
at java.util.jar.JarFile.(JarFile.java:166) ~[?:1.8.0_101]
at java.util.jar.JarFile.(JarFile.java:103) ~[?:1.8.0_101]
at org.elasticsearch.bootstrap.JarHell.checkJarHell(JarHell.java:175) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.JarHell.checkJarHell(JarHell.java:88) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:230) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:360) ~[elasticsearch-5.3.2.jar:5.3.2]
at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:123) ~[elasticsearch-5.3.2.jar:5.3.2]
... 6 more

I tried running from another external drive (also solid state) and got the same error, however when I moved it to the Macs hard drive, it started perfectly well.

What additional setup steps are required for an external drive?

Are you sure your external drive is not corrupt? Have you run filesystem and/or hardware checks? What operating system? What filesystem is the external drive formatted with?

Hi Ryan,
I tested the problem on 2 different external drives, both SSDs of different brands. File system is exFAT
I am running El Capitan 10.11.3 on my MAC.

Ok - switched over the file system to HFS+ on the drives - all good!!! It must have been something due to the exFAT file system that isn't as compatible with MACS.
Thank you very much for the suggestion.
Anton

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.