# Set up and maintain ES as primary database

**URL:** <https://discuss.elastic.co/t/set-up-and-maintain-es-as-primary-database/169349>\
**Category:** Elasticsearch\
**Created:** [February 21, 2019, 8:43am UTC](https://discuss.elastic.co/t/set-up-and-maintain-es-as-primary-database/169349 "2019-02-21T08:43:37Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![freaka](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/freaka/32/41962_2.png) [@freaka](https://discuss.elastic.co/u/freaka)\
**Post date:** [February 21, 2019, 8:43am UTC](https://discuss.elastic.co/t/set-up-and-maintain-es-as-primary-database/169349/1 "2019-02-21T08:43:38Z")

</div>

Hello,

the chosen database for our current project is Elasticsearch as it is handy enough for JSON documents and our project involves only JSON documents (data-wise).

I'm a bit concerned because no one in the company is fluent in elasticsearch. I have questions regarding 2 things:

- as I understand, we will have only a VM to deploy all of our modules (.jar mostly) and elasticsearch. How much RAM and CPU should we give to ES in a context where at most 60.000 requests could be sent for create/update and between [0-60.000] requests could be sent for search/get (this 60.000 number is conservative, I would expect something like a peak load of 10.000 users maximum, thus resulting in approximately 10.000 get/search requests)
- I know snapshots can be scheduled every half hour or so to secure the data (that frequency seems ok to me, relative to the value of the data).
- How do I know how to size my elasticsearch database ? What are the main parameters to consider ? For example when I test on my machine I see health is YELLOW and for example I don't know how to go from there to GREEN.

Sorry this post might be messy but I want to make sure elasticsearch is a suitable solution as a primary database, otherwise we need to look somewhere else.

Thanks 🙂

---

<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:** [February 21, 2019, 9:36am UTC](https://discuss.elastic.co/t/set-up-and-maintain-es-as-primary-database/169349/2 "2019-02-21T09:36:05Z")

</div>

May I suggest you look at the following resources about sizing:

> **[Quantitative Cluster Sizing](https://www.elastic.co/elasticon/conf/2016/sf/quantitative-cluster-sizing)**

> **[How many shards should I have in my Elasticsearch cluster?](https://www.elastic.co/blog/how-many-shards-should-i-have-in-my-elasticsearch-cluster)**

> **[Managing your black Friday logs - CloudConf.IT](https://www.slideshare.net/dadoonet/managing-your-black-friday-logs-cloudconfit-93309899)**
>
> Managing your black Friday logs - CloudConf.IT - Download as a PDF or view online for free

[![](https://us1.discourse-cdn.com/elastic/original/3X/7/c/7c2edebd5bac194c58a5df87ede6872cb41d61a8.jpeg "Managing your Black Friday Logs, Pablo Musa, Elastic, TechSummit Amsterdam") ](https://www.youtube.com/watch?v=ilP7tG6tabI)

And [https://www.elastic.co/webinars/using-rally-to-get-your-elasticsearch-cluster-size-right](https://www.elastic.co/webinars/using-rally-to-get-your-elasticsearch-cluster-size-right)

> For example when I test on my machine I see health is YELLOW and for example I don't know how to go from there to GREEN.

It's because you have only one node running but you have a number of replicas equal to 1 (default value). Which means that replicas can't be allocated anywhere, hence that yellow status.  
Either change the index settings and set the number of replicas to 0, or start a new node, or just ignore this. This is fine for tests.

---

<div class="post-metadata">

**Author:** ![freaka](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/freaka/32/41962_2.png) [@freaka](https://discuss.elastic.co/u/freaka)\
**Post date:** [February 21, 2019, 9:39am UTC](https://discuss.elastic.co/t/set-up-and-maintain-es-as-primary-database/169349/3 "2019-02-21T09:39:04Z")

</div>

Thanks a lot! I will dig into these resources and learn.

---

<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:** [March 21, 2019, 9:39am UTC](https://discuss.elastic.co/t/set-up-and-maintain-es-as-primary-database/169349/4 "2019-03-21T09:39:05Z")

</div>

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