# Installing X-Pack with --version is installing the wrong version

**URL:** <https://discuss.elastic.co/t/installing-x-pack-with-version-is-installing-the-wrong-version/87715>\
**Category:** Elasticsearch\
**Created:** [May 31, 2017, 10:27am UTC](https://discuss.elastic.co/t/installing-x-pack-with-version-is-installing-the-wrong-version/87715 "2017-05-31T10:27:42Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![AlexW](https://avatars.discourse-cdn.com/v4/letter/a/b5a626/32.png) [@AlexW](https://discuss.elastic.co/u/AlexW)\
**Post date:** [May 31, 2017, 10:27am UTC](https://discuss.elastic.co/t/installing-x-pack-with-version-is-installing-the-wrong-version/87715/1 "2017-05-31T10:27:42Z")

</div>

Hi!

If I install X-Pack on a Logstash 5.3.2 with this command:

> /usr/share/logstash/bin/logstash-plugin install --version 5.3.0 x-pack

it installs version 5.3.2.

You will now say, that this is correct as I am using Logstash 5.3.2 but when using Puppet to do so you run in serious problems. What happens is:

- I told puppet to install 5.3.0 (which is wrong)
- Puppet checked the version of the installed x-pack, as no x-pack is installed it comes back empty
- Puppet installes with the above command
- X-Pack v5.3.2 is installed

Next Puppet run:

- Puppet checks the version and gets v5.3.2 which is != v5.3.0
- Puppet installs v5.3.0 with above command, wich again install v5.3.2

This happens in an endles loop and restarts Logstash over and over everytime Puppet runs.

My question: Why don't I get the version I want to install or at least an error message?

Thank you for your help,  
Alex

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [May 31, 2017, 11:10pm UTC](https://discuss.elastic.co/t/installing-x-pack-with-version-is-installing-the-wrong-version/87715/2 "2017-05-31T23:10:05Z")

</div>

The plugin command will always install the version it needs, there is no option to pass in a specific version argument.

---

<div class="post-metadata">

**Author:** ![AlexW](https://avatars.discourse-cdn.com/v4/letter/a/b5a626/32.png) [@AlexW](https://discuss.elastic.co/u/AlexW)\
**Post date:** [June 2, 2017, 2:39pm UTC](https://discuss.elastic.co/t/installing-x-pack-with-version-is-installing-the-wrong-version/87715/4 "2017-06-02T14:39:03Z")

</div>

Hi!

Thank you for your answer.  
This is the help for the command "install":

```
/usr/share/logstash/bin# ./logstash-plugin install -h
Usage:
    bin/logstash-plugin install [OPTIONS] [PLUGIN] ...

Parameters:
    [PLUGIN] ... plugin name(s) or file

Options:
    --version VERSION version of the plugin to install
    --[no-]verify verify plugin validity before installation (default: true)
    --preserve preserve current gem options (default: false)
    --development install all development dependencies of currently installed plugins (default: false)
    --local force local-only plugin installation. see bin/logstash-plugin package|unpack (default: false)
    -h, --help print help

```

So there is the parameter --version. And this parameter is used by the Puppet Module of Logstash. So if I specify a version there it should install exactly that version or (even better) exit with an error. But just installing a different version is not correct and I think it is a bug.

Regards,  
Alex

---

<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:** [June 30, 2017, 2:39pm UTC](https://discuss.elastic.co/t/installing-x-pack-with-version-is-installing-the-wrong-version/87715/5 "2017-06-30T14:39:05Z")

</div>

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