# Error while installing X-Pack license

**URL:** <https://discuss.elastic.co/t/error-while-installing-x-pack-license/68431>\
**Category:** Elasticsearch\
**Created:** [December 8, 2016, 11:53am UTC](https://discuss.elastic.co/t/error-while-installing-x-pack-license/68431 "2016-12-08T11:53:12Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![elasticheart](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/elasticheart/32/65189_2.png) [@elasticheart](https://discuss.elastic.co/u/elasticheart)\
**Post date:** [December 8, 2016, 11:53am UTC](https://discuss.elastic.co/t/error-while-installing-x-pack-license/68431/1 "2016-12-08T11:53:12Z")

</div>

Hi,

When I try to install X-Pack license using the command;

```
curl -XPUT -u user 'http://localhost:9200/_license&acknowledge=true' -d @/license/license.json

```

I am getting the following error;

```
{"error":{"root_cause":[{"type":"illegal_argument_exception","reason":"unknown setting [index.license.expiry_date_in_millis] please check that any required plugins are installed, or check the breaking changes documentation for removed settings"}],"type":"illegal_argument_exception","reason":"unknown setting [index.license.expiry_date_in_millis] please check that any required plugins are installed, or check the breaking changes documentation for removed settings"},"status":400}

```

How can I fix this?

Thanks.

---

<div class="post-metadata">

**Author:** ![colings86](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/colings86/32/44960_2.png) [@colings86](https://discuss.elastic.co/u/colings86)\
**Post date:** [December 8, 2016, 12:07pm UTC](https://discuss.elastic.co/t/error-while-installing-x-pack-license/68431/2 "2016-12-08T12:07:19Z")

</div>

Is your licence for X-Pack or are you trying to use an existing license (for e.g. Shield/Watcher/Marvel) with X-Pack. You need a licence specifically for X-Pack to use with 5.0.

If you are a subscription customer you can either raise a ticket on the support portal or speak to your Sales Representative to request an X-Pack license for your subscription.

---

<div class="post-metadata">

**Author:** ![elasticheart](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/elasticheart/32/65189_2.png) [@elasticheart](https://discuss.elastic.co/u/elasticheart)\
**Post date:** [December 8, 2016, 12:09pm UTC](https://discuss.elastic.co/t/error-while-installing-x-pack-license/68431/3 "2016-12-08T12:09:15Z")

</div>

Hi @colings86 I got the license from here [https://register.elastic.co/xpack\_register](https://register.elastic.co/xpack_register)

---

<div class="post-metadata">

**Author:** ![colings86](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/colings86/32/44960_2.png) [@colings86](https://discuss.elastic.co/u/colings86)\
**Post date:** [December 8, 2016, 12:15pm UTC](https://discuss.elastic.co/t/error-while-installing-x-pack-license/68431/4 "2016-12-08T12:15:17Z")

</div>

Ok. could you paste the output of `curl -XGET "http://localhost:9200"` here and I'll ask one of the devs who knows more about licensing to look at this

---

<div class="post-metadata">

**Author:** ![elasticheart](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/elasticheart/32/65189_2.png) [@elasticheart](https://discuss.elastic.co/u/elasticheart)\
**Post date:** [December 8, 2016, 12:23pm UTC](https://discuss.elastic.co/t/error-while-installing-x-pack-license/68431/5 "2016-12-08T12:23:58Z")

</div>

```
{
  "name" : "mynode",
  "cluster_name" : "mycluster",
  "cluster_uuid" : "hmiKt6unSHWphX8PUiJXIA",
  "version" : {
    "number" : "5.0.0",
    "build_hash" : "253032b",
    "build_date" : "2016-10-26T04:37:51.531Z",
    "build_snapshot" : false,
    "lucene_version" : "6.2.0"
  },
  "tagline" : "You Know, for Search"
}
```

---

<div class="post-metadata">

**Author:** ![nick.e](https://avatars.discourse-cdn.com/v4/letter/n/8dc957/32.png) [@nick.e](https://discuss.elastic.co/u/nick.e)\
**Post date:** [December 8, 2016, 1:32pm UTC](https://discuss.elastic.co/t/error-while-installing-x-pack-license/68431/6 "2016-12-08T13:32:17Z")

</div>

When installing a license for X-Pack on a cluster with version 5.0 or higher you need to use the following command:

> curl -XPUT -u user '[http://localhost:9200/\_xpack/license](http://localhost:9200/_xpack/license)' -d @/license/license.json

The \_license index is obsolete. \_xpack/license is the correct one. (see: [License Management | X-Pack for the Elastic Stack [6.2] | Elastic](https://www.elastic.co/guide/en/x-pack/current/installing-license.html))

---

<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:** [January 5, 2017, 1:32pm UTC](https://discuss.elastic.co/t/error-while-installing-x-pack-license/68431/7 "2017-01-05T13:32:23Z")

</div>

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