# Multi cluster / multi-tenancy elastic environment

**URL:** <https://discuss.elastic.co/t/multi-cluster-multi-tenancy-elastic-environment/150099>\
**Category:** Elasticsearch\
**Created:** [September 27, 2018, 1:23am UTC](https://discuss.elastic.co/t/multi-cluster-multi-tenancy-elastic-environment/150099 "2018-09-27T01:23:39Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![btom](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/btom/32/13953_2.png) [@btom](https://discuss.elastic.co/u/btom)\
**Post date:** [September 27, 2018, 1:23am UTC](https://discuss.elastic.co/t/multi-cluster-multi-tenancy-elastic-environment/150099/1 "2018-09-27T01:23:39Z")

</div>

Hi,

I want to store data of three different customer on to same elastic host. Just wondering what is the best way to achieve this with security. ( The data of all customer should be secure and not visible to each other) ?

1. How to create more than one cluster on same host using Java API?
2. Can we achieve multi-tenancy environment with security?

An example would be much appreciated.

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:** [September 27, 2018, 5:38am UTC](https://discuss.elastic.co/t/multi-cluster-multi-tenancy-elastic-environment/150099/2 "2018-09-27T05:38:33Z")

</div>

> 1. How to create more than one cluster on same host using Java API?

I don't know of any easy way to do this through Java. Usually some orchestration tool, e.g. Ansible or Puppet, are used for this.

> 1. Can we achieve multi-tenancy environment with security?

X-Pack Security can handle this, both at index and document level. It would help if you provided some additional information about number of customers, expected data volumes and other requirements though.

---

<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:** [October 25, 2018, 5:38am UTC](https://discuss.elastic.co/t/multi-cluster-multi-tenancy-elastic-environment/150099/3 "2018-10-25T05:38:33Z")

</div>

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