# Error while installing X-pack on windows

**URL:** <https://discuss.elastic.co/t/error-while-installing-x-pack-on-windows/201310>\
**Category:** Elasticsearch\
**Created:** [September 26, 2019, 8:07pm UTC](https://discuss.elastic.co/t/error-while-installing-x-pack-on-windows/201310 "2019-09-26T20:07:47Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![humza-cyber](https://avatars.discourse-cdn.com/v4/letter/h/48db29/32.png) [@humza-cyber](https://discuss.elastic.co/u/humza-cyber)\
**Post date:** [September 26, 2019, 8:07pm UTC](https://discuss.elastic.co/t/error-while-installing-x-pack-on-windows/201310/1 "2019-09-26T20:07:47Z")

</div>

I have elastic 5.5.0, downloaded in zip format, on Windows. I'm trying to install X-pack 5.5.3. As per [Elastic support matrix](https://www.elastic.co/support/matrix#matrix_compatibility) it is compatible but getting an error will installing it. Here is the error log

C:\elasticsearch-5.5.0\bin\>elasticsearch-plugin install file:///C:/temp/x-pack-5.5.3.zip  
-\> Downloading file:///C:/temp/x-pack-5.5.3.zip  
[=================================================] 100%  
Exception in thread "main" java.lang.IllegalArgumentException: plugin [x-pack] is incompatible with version [5.5.0]; was designed for version [5.5.3]  
at org.elasticsearch.plugins.PluginInfo.readFromProperties(PluginInfo.java:146)  
at org.elasticsearch.plugins.InstallPluginCommand.verify(InstallPluginCommand.java:474)  
at org.elasticsearch.plugins.InstallPluginCommand.install(InstallPluginCommand.java:543)  
at org.elasticsearch.plugins.InstallPluginCommand.execute(InstallPluginCommand.java:217)  
at org.elasticsearch.plugins.InstallPluginCommand.execute(InstallPluginCommand.java:201)  
at org.elasticsearch.cli.EnvironmentAwareCommand.execute(EnvironmentAwareCommand.java:67)  
at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:122)  
at org.elasticsearch.cli.MultiCommand.execute(MultiCommand.java:69)  
at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:122)  
at org.elasticsearch.cli.Command.main(Command.java:88)  
at org.elasticsearch.plugins.PluginCli.main(PluginCli.java:47)

Does anyone else has/had the same issue?  
Thanks

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [September 26, 2019, 11:49pm UTC](https://discuss.elastic.co/t/error-while-installing-x-pack-on-windows/201310/2 "2019-09-26T23:49:34Z")

</div>

You must install the exact same version.  
5.5.0 vs 5.5.3.

---

<div class="post-metadata">

**Author:** ![humza-cyber](https://avatars.discourse-cdn.com/v4/letter/h/48db29/32.png) [@humza-cyber](https://discuss.elastic.co/u/humza-cyber)\
**Post date:** [September 27, 2019, 7:00pm UTC](https://discuss.elastic.co/t/error-while-installing-x-pack-on-windows/201310/3 "2019-09-27T19:00:21Z")

</div>

Could not find x-pack 5.5.0 setup but on website they say x-pack 5.5.0 for Elastic search 5.5.3. Any solution recommended? I can't change the Elastic version as I have to stick with what is already on the servers.

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [September 28, 2019, 4:32am UTC](https://discuss.elastic.co/t/error-while-installing-x-pack-on-windows/201310/4 "2019-09-28T04:32:29Z")

</div>

Run:

```
elasticsearch-plugin install x-pack
```

---

<div class="post-metadata">

**Author:** ![humza-cyber](https://avatars.discourse-cdn.com/v4/letter/h/48db29/32.png) [@humza-cyber](https://discuss.elastic.co/u/humza-cyber)\
**Post date:** [September 30, 2019, 1:59pm UTC](https://discuss.elastic.co/t/error-while-installing-x-pack-on-windows/201310/5 "2019-09-30T13:59:10Z")

</div>

Hi, thank you for your reply. If I try to run this command **elasticsearch-plugin install x-pack** on **gitbash** it throws me this error  
**Error: Could not find or load main class org.elasticsearch.plugins.PluginCli**

And on **CMD** it throws

Exception in thread "main" java.net.UnknownHostException: [artifacts.elastic.co](http://artifacts.elastic.co)  
at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:184)  
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:172)  
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)  
at java.net.Socket.connect(Socket.java:589)  
at sun.security.ssl.SSLSocketImpl.connect(SSLSocketImpl.java:666)  
at sun.security.ssl.BaseSSLSocketImpl.connect(BaseSSLSocketImpl.java:173)  
at sun.net.NetworkClient.doConnect(NetworkClient.java:180)  
at sun.net.www.http.HttpClient.openServer(HttpClient.java:463)  
at sun.net.www.http.HttpClient.openServer(HttpClient.java:558)  
at sun.net.www.protocol.https.HttpsClient.(HttpsClient.java:264)  
at sun.net.www.protocol.https.HttpsClient.New(HttpsClient.java:367)  
at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.getNewHttpClient(AbstractDelegateHttpsURLConnection.java:191)  
at sun.net.www.protocol.http.HttpURLConnection.plainConnect0(HttpURLConnection.java:1156)  
at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:1050)  
at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(AbstractDelegateHttpsURLConnection.java:177)  
at sun.net.www.protocol.https.HttpsURLConnectionImpl.connect(HttpsURLConnectionImpl.java:162)  
at org.elasticsearch.plugins.InstallPluginCommand.urlExists(InstallPluginCommand.java:300)  
at org.elasticsearch.plugins.InstallPluginCommand.getElasticUrl(InstallPluginCommand.java:267)  
at org.elasticsearch.plugins.InstallPluginCommand.download(InstallPluginCommand.java:223)  
at org.elasticsearch.plugins.InstallPluginCommand.execute(InstallPluginCommand.java:215)  
at org.elasticsearch.plugins.InstallPluginCommand.execute(InstallPluginCommand.java:201)  
at org.elasticsearch.cli.EnvironmentAwareCommand.execute(EnvironmentAwareCommand.java:67)  
at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:122)  
at org.elasticsearch.cli.MultiCommand.execute(MultiCommand.java:69)  
at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:122)  
at org.elasticsearch.cli.Command.main(Command.java:88)  
at org.elasticsearch.plugins.PluginCli.main(PluginCli.java:47)

which apparently looks to me **proxy** issue. I tried to use this command

**set ES\_JAVA\_OPTS="-Dhttp.proxyHost=host\_name -Dhttp.proxyPort=port\_number -Dhttps.proxyHost=host\_name -Dhttps.proxyPort=https\_port\_number"**  
but it does not seem to work.

And if I **run** elastic search through **CMD** using this **'elasticsearch'** it runs but on **gitbash** it says  
**Error: Could not find or load main class org.elasticsearch.tools.JavaVersionChecker**  
**Elasticsearch requires at least Java 8 but your Java version from C:\Program Files\Java\jdk1.8.0\_192/bin/java does not meet this requirement**.

I checked the java version using 'java -version' that's what I get  
**java version "1.8.0\_192"**  
**Java(TM) SE Runtime Environment (build 1.8.0\_192-b12)**  
**Java HotSpot(TM) 64-Bit Server VM (build 25.192-b12, mixed mode)**

Any guess what could be the possible issue? Thanks.

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [September 30, 2019, 2:14pm UTC](https://discuss.elastic.co/t/error-while-installing-x-pack-on-windows/201310/6 "2019-09-30T14:14:13Z")

</div>

I think you should better use a more recent version of elasticsearch.  
IIRC there was issues with java version detection in the past on Windows.

You should consider (my order of preference):

- 7.3.2
- 6.8.3
- 5.6.16 (if you really can't use 7.x or 6.x)

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [October 28, 2019, 2:14pm UTC](https://discuss.elastic.co/t/error-while-installing-x-pack-on-windows/201310/7 "2019-10-28T14:14:17Z")

</div>

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