# Adding rack awareness to Elasticsearch cluster on GKE

**URL:** <https://discuss.elastic.co/t/adding-rack-awareness-to-elasticsearch-cluster-on-gke/202888>\
**Category:** Elasticsearch\
**Created:** [October 9, 2019, 5:25pm UTC](https://discuss.elastic.co/t/adding-rack-awareness-to-elasticsearch-cluster-on-gke/202888 "2019-10-09T17:25:29Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![pinakinab](https://avatars.discourse-cdn.com/v4/letter/p/bcef8e/32.png) [@pinakinab](https://discuss.elastic.co/u/pinakinab)\
**Post date:** [October 9, 2019, 5:25pm UTC](https://discuss.elastic.co/t/adding-rack-awareness-to-elasticsearch-cluster-on-gke/202888/1 "2019-10-09T17:25:29Z")

</div>

We are trying to setup elasticsearch cluster on GKE. We are using official helm chart of elasticsearch for the same. We are able to setup a cluster. However we are not able to add allocation awareness attributes in the cluster.

The attribute that we are looking for high availability in GKE is **zone** which is available through **[failure-domain.beta.kubernetes.io/zone](http://failure-domain.beta.kubernetes.io/zone)** label inside GKE node.

We want this label to be available inside pod so that we can use it for rack awareness. We found that node labels cannot be made available inside pod and here is the [open issue](https://github.com/kubernetes/kubernetes/issues/40610) for the same.

After searching on internet for this we found following [solution](https://gmaslowski.com/kubernetes-node-label-to-pod/).

Can anybody suggest me a cleaner solution?

---

<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:** [November 6, 2019, 5:25pm UTC](https://discuss.elastic.co/t/adding-rack-awareness-to-elasticsearch-cluster-on-gke/202888/2 "2019-11-06T17:25:38Z")

</div>

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