# How to Properly Use The Roles in values.yaml?

**URL:** <https://discuss.elastic.co/t/how-to-properly-use-the-roles-in-values-yaml/298962>\
**Category:** Elasticsearch\
**Created:** [March 7, 2022, 12:07pm UTC](https://discuss.elastic.co/t/how-to-properly-use-the-roles-in-values-yaml/298962 "2022-03-07T12:07:16Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![lloyd01sanchez12](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/lloyd01sanchez12/32/102690_2.png) [@lloyd01sanchez12](https://discuss.elastic.co/u/lloyd01sanchez12)\
**Post date:** [March 7, 2022, 12:07pm UTC](https://discuss.elastic.co/t/how-to-properly-use-the-roles-in-values-yaml/298962/1 "2022-03-07T12:07:16Z")

</div>

Hi Team,

I've been having a problem correcting the deprecation warnings related to node.roles:

```auto
"message": "legacy role settings [node.data, node.remote_cluster_client, node.ingest, node.master, node.ml] are deprecated, use [node.roles=[transform, data_frozen, master, data, data_content, data_hot, data_warm, data_cold]]"

```

This is so far the values I am using for our ES multi-cluster:

```auto
nodeGroup: "master"
replicas: 3

roles:
  master: "true"
  ingest: "false"
  data: "true"
  remote_cluster_client: "false"
  ml: "false"

esConfig:
  elasticsearch.yml: |
    xpack.security.enabled: false

resources:
  requests:
    cpu: "100m"
    memory: "4Gi"

  limits:
    cpu: "1"
    memory: "4Gi"

volumeClaimTemplate:
  accessModes: ["ReadWriteOnce"]
  storageClassName: monitoring
  resources:
    requests:
      storage: 4Gi

```

We are using the latest chart version 7.16.3. With this, will this new set of values work for the node roles?

```auto
nodeGroup: "master"
replicas: 3

roles:
  - master

```

And no definition for node.roles should be added within the `elasticsearch.yml`?

Thanks in advance! Apologies, I've been stuck on correcting the deprecation warnings and your response will highly be appreciated!

---

<div class="post-metadata">

**Author:** ![sagarpatel](https://avatars.discourse-cdn.com/v4/letter/s/ebca7d/32.png) [@sagarpatel](https://discuss.elastic.co/u/sagarpatel)\
**Post date:** [March 7, 2022, 1:08pm UTC](https://discuss.elastic.co/t/how-to-properly-use-the-roles-in-values-yaml/298962/2 "2022-03-07T13:08:10Z")

</div>

Please check [this](https://github.com/elastic/helm-charts/blob/7.16/elasticsearch/values.yaml) documentation. they have still define values in old way only. Also, Chart 7.17 is support old way. this will be coming in next release as i can see changes in Main branch which is showing roles in new way.

---

<div class="post-metadata">

**Author:** ![lloyd01sanchez12](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/lloyd01sanchez12/32/102690_2.png) [@lloyd01sanchez12](https://discuss.elastic.co/u/lloyd01sanchez12)\
**Post date:** [March 8, 2022, 12:59am UTC](https://discuss.elastic.co/t/how-to-properly-use-the-roles-in-values-yaml/298962/3 "2022-03-08T00:59:11Z")

</div>

Thanks sagarpatel, yeah, it looks like they still are using the old format. But would you know how to resolve the deprecation warning such as below:

```auto
{"type": "deprecation.elasticsearch", "timestamp": "2022-03-07T07:56:19,152Z", "level": "CRITICAL", "component": "o.e.d.c.s.Settings", "cluster.name": "elasticsearch", "node.name": "elasticsearch-data-0", "message": "[node.ml] setting was deprecated in Elasticsearch and will be removed in a future release! See the breaking changes documentation for the next major version.", "key": "node.ml", "category": "settings" }
{"type": "deprecation.elasticsearch", "timestamp": "2022-03-07T07:56:19,177Z", "level": "CRITICAL", "component": "o.e.d.c.s.Settings", "cluster.name": "elasticsearch", "node.name": "elasticsearch-data-0", "message": "[node.data] setting was deprecated in Elasticsearch and will be removed in a future release! See the breaking changes documentation for the next major version.", "key": "node.data", "category": "settings" }
{"type": "deprecation.elasticsearch", "timestamp": "2022-03-07T07:56:19,241Z", "level": "CRITICAL", "component": "o.e.d.c.s.Settings", "cluster.name": "elasticsearch", "node.name": "elasticsearch-data-0", "message": "[node.master] setting was deprecated in Elasticsearch and will be removed in a future release! See the breaking changes documentation for the next major version.", "key": "node.master", "category": "settings" }
{"type": "deprecation.elasticsearch", "timestamp": "2022-03-07T07:56:19,246Z", "level": "CRITICAL", "component": "o.e.d.c.s.Settings", "cluster.name": "elasticsearch", "node.name": "elasticsearch-data-0", "message": "[node.remote_cluster_client] setting was deprecated in Elasticsearch and will be removed in a future release! See the breaking changes documentation for the next major version.", "key": "node.remote_cluster_client", "category": "settings" }
{"type": "deprecation.elasticsearch", "timestamp": "2022-03-07T07:56:19,252Z", "level": "CRITICAL", "component": "o.e.d.c.s.Settings", "cluster.name": "elasticsearch", "node.name": "elasticsearch-data-0", "message": "[node.ingest] setting was deprecated in Elasticsearch and will be removed in a future release! See the breaking changes documentation for the next major version.", "key": "node.ingest", "category": "settings" }
{"type": "deprecation.elasticsearch", "timestamp": "2022-03-07T07:56:19,349Z", "level": "CRITICAL", "component": "o.e.d.n.Node", "cluster.name": "elasticsearch", "node.name": "elasticsearch-data-0", "message": "legacy role settings [node.data, node.remote_cluster_client, node.ingest, node.master, node.ml] are deprecated, use [node.roles=[transform, data_frozen, data, data_content, data_hot, data_warm, data_cold, ingest]]", "key": "legacy role settings", "category": "settings" }

```

These are all node related deprecation warnings.

---

<div class="post-metadata">

**Author:** ![sagarpatel](https://avatars.discourse-cdn.com/v4/letter/s/ebca7d/32.png) [@sagarpatel](https://discuss.elastic.co/u/sagarpatel)\
**Post date:** [March 8, 2022, 4:43am UTC](https://discuss.elastic.co/t/how-to-properly-use-the-roles-in-values-yaml/298962/4 "2022-03-08T04:43:58Z")

</div>

You can use current functionality with deprecation log and to resolved this you need to upgrade version. If you want to test then you can provide roles in new way and tried out but my understanding is, it will not worked. So go with current version as of now and when new version release upgrade it (chart).

---

<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:** [April 5, 2022, 4:44am UTC](https://discuss.elastic.co/t/how-to-properly-use-the-roles-in-values-yaml/298962/5 "2022-04-05T04:44:00Z")

</div>

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