# Connecting 2 clusters in kubernetes

**URL:** <https://discuss.elastic.co/t/connecting-2-clusters-in-kubernetes/204164>\
**Category:** Elasticsearch\
**Created:** [October 18, 2019, 5:17am UTC](https://discuss.elastic.co/t/connecting-2-clusters-in-kubernetes/204164 "2019-10-18T05:17:00Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![SukeshGupta](https://avatars.discourse-cdn.com/v4/letter/s/91b2a8/32.png) [@SukeshGupta](https://discuss.elastic.co/u/SukeshGupta)\
**Post date:** [October 18, 2019, 5:17am UTC](https://discuss.elastic.co/t/connecting-2-clusters-in-kubernetes/204164/1 "2019-10-18T05:17:00Z")

</div>

Hi,

I have one cluster in zone-1 with 2 nodes and I have one more cluster in zone-2 with 2 nodes and both the clusters are having the same cluster name. Would like know how to establish a connection between 2 clusters in kubernetes.  
Requesting anyone to please help me on this. Thanks!

---

<div class="post-metadata">

**Author:** ![Christian\_Dahlqvist](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/christian_dahlqvist/32/4617_2.png) [@Christian\_Dahlqvist](https://discuss.elastic.co/u/Christian_Dahlqvist)\
**Post date:** [October 19, 2019, 8:20am UTC](https://discuss.elastic.co/t/connecting-2-clusters-in-kubernetes/204164/2 "2019-10-19T08:20:17Z")

</div>

If they had different names you could connect them through cross-cluster search, so I would recommend recreating and renaming one of them. Not sure if there is any way to connect two clusters with the same name.

---

<div class="post-metadata">

**Author:** ![deepakkumar](https://avatars.discourse-cdn.com/v4/letter/d/ee7513/32.png) [@deepakkumar](https://discuss.elastic.co/u/deepakkumar)\
**Post date:** [October 21, 2019, 10:30am UTC](https://discuss.elastic.co/t/connecting-2-clusters-in-kubernetes/204164/3 "2019-10-21T10:30:41Z")

</div>

According to Elastic Doc , All clusters must be in the same Elasticsearch environment, region, and owned by the same user.  
But in out case , we have two different cluster(cluster name I will be managed) in different region. According to client requirement, both cluster should be communicate to each other. Example : user added one document in cluster A, us- region , the same document should be display when user search in cluster B, aisa region.  
Kindly help me. Thank you!

---

<div class="post-metadata">

**Author:** ![Christian\_Dahlqvist](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/christian_dahlqvist/32/4617_2.png) [@Christian\_Dahlqvist](https://discuss.elastic.co/u/Christian_Dahlqvist)\
**Post date:** [October 21, 2019, 10:48am UTC](https://discuss.elastic.co/t/connecting-2-clusters-in-kubernetes/204164/4 "2019-10-21T10:48:13Z")

</div>

I would recommend recreating one of the clusters with a different name and configure cross-cluster search.

---

<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:** [October 21, 2019, 10:54am UTC](https://discuss.elastic.co/t/connecting-2-clusters-in-kubernetes/204164/5 "2019-10-21T10:54:23Z")

</div>

Adding to @Christian_Dahlqvist answer that you can also look at [https://www.elastic.co/guide/en/elasticsearch/reference/current/xpack-ccr.html](https://www.elastic.co/guide/en/elasticsearch/reference/current/xpack-ccr.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:** [November 18, 2019, 10:59am UTC](https://discuss.elastic.co/t/connecting-2-clusters-in-kubernetes/204164/6 "2019-11-18T10:59:41Z")

</div>

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