# Use azure fileshare as data storage for Multiple ES Clusters running on K8s

**URL:** <https://discuss.elastic.co/t/use-azure-fileshare-as-data-storage-for-multiple-es-clusters-running-on-k8s/217155>\
**Category:** Elasticsearch\
**Created:** [January 30, 2020, 10:26am UTC](https://discuss.elastic.co/t/use-azure-fileshare-as-data-storage-for-multiple-es-clusters-running-on-k8s/217155 "2020-01-30T10:26:56Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![biswarup1290dass](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/biswarup1290dass/32/61725_2.png) [@biswarup1290dass](https://discuss.elastic.co/u/biswarup1290dass)\
**Post date:** [January 30, 2020, 10:26am UTC](https://discuss.elastic.co/t/use-azure-fileshare-as-data-storage-for-multiple-es-clusters-running-on-k8s/217155/1 "2020-01-30T10:26:56Z")

</div>

Is it possible to use an Azure File Share(similar to NFS) for data storage of multiple ES Clusters running on K8s? So that both the clusters can write/read from a common location. Can think of it as a cross-geo HA solution.

---

<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:** [January 30, 2020, 11:52am UTC](https://discuss.elastic.co/t/use-azure-fileshare-as-data-storage-for-multiple-es-clusters-running-on-k8s/217155/2 "2020-01-30T11:52:15Z")

</div>

Welcome!

It's absolutely not recommended to store data on network drives and to split a cluster across multiple regions.

Instead use the cross cluster replication feature (which I think is a commercial feature though).

---

<div class="post-metadata">

**Author:** ![biswarup1290dass](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/biswarup1290dass/32/61725_2.png) [@biswarup1290dass](https://discuss.elastic.co/u/biswarup1290dass)\
**Post date:** [January 30, 2020, 12:37pm UTC](https://discuss.elastic.co/t/use-azure-fileshare-as-data-storage-for-multiple-es-clusters-running-on-k8s/217155/3 "2020-01-30T12:37:08Z")

</div>

Thanks @dadoonet.

Point noted.

The goal is to achieve a live migration with 0 downtime, CCR Feature guarantees that? Like a seamless migration.

---

<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:** [January 30, 2020, 1:42pm UTC](https://discuss.elastic.co/t/use-azure-fileshare-as-data-storage-for-multiple-es-clusters-running-on-k8s/217155/4 "2020-01-30T13:42:33Z")

</div>

Live migration of what?  
Why across multiple regions ?

---

<div class="post-metadata">

**Author:** ![biswarup1290dass](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/biswarup1290dass/32/61725_2.png) [@biswarup1290dass](https://discuss.elastic.co/u/biswarup1290dass)\
**Post date:** [January 30, 2020, 5:01pm UTC](https://discuss.elastic.co/t/use-azure-fileshare-as-data-storage-for-multiple-es-clusters-running-on-k8s/217155/5 "2020-01-30T17:01:08Z")

</div>

(Long post alert!)  
If not across multiple region, is the below requirement achievable via CCR Feature on a single region?

Requirement:  
A K8s Cluster(ECK\_CLUSTER\_A) running with ES deployed with Data pods running on 3 different zones in a specific region (lets say West Europe). Lets say this cluster has some data stored.  
Spin up a new cluster(ECK\_CLUSTER\_B) on same region (West Europe) and deploy ES having the same configuration as above).  
Scenario 1: How do I store the data, so that its accessible from Both the clusters.?  
Scenario 2: In case ECK\_CLUSTER\_A gets destroyed, how can I access the same data from the newly spun Cluster ECK\_CLUSTER\_B?

Correct me if I am wrong but I guess the scenario 2 portrays somewhat like a live-migration of the ES service with no downtime.

---

<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:** [January 30, 2020, 8:24pm UTC](https://discuss.elastic.co/t/use-azure-fileshare-as-data-storage-for-multiple-es-clusters-running-on-k8s/217155/6 "2020-01-30T20:24:20Z")

</div>

Every Elasticsearch node need a dedicated area to store data, which can not be shared with other nodes inside or outside the cluster. This area usually also stores cluster state so can not be brought up on a node within a different cluster. Both scenario 1 and 2 are therefore unlikely to work.

CCR is probably the easiest way to set this up, but before CCR was available a common method was to set up two separate clusters and write to them in parallel so they all receive the same data and stay in sync, often by using a message queue to allow for buffering in case of failures.

---

<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:** [February 27, 2020, 8:24pm UTC](https://discuss.elastic.co/t/use-azure-fileshare-as-data-storage-for-multiple-es-clusters-running-on-k8s/217155/7 "2020-02-27T20:24:24Z")

</div>

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