# Dec 7th: \[EN\]\[Elasticsearch\] Holiday-proof your cluster

**URL:** <https://discuss.elastic.co/t/dec-7th-en-elasticsearch-holiday-proof-your-cluster/110195>\
**Category:** Advent Calendar\
**Created:** [December 6, 2017, 1:00pm UTC](https://discuss.elastic.co/t/dec-7th-en-elasticsearch-holiday-proof-your-cluster/110195 "2017-12-06T13:00:07Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![cwurm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/cwurm/32/34882_2.png) [@cwurm](https://discuss.elastic.co/u/cwurm)\
**Post date:** [December 6, 2017, 1:00pm UTC](https://discuss.elastic.co/t/dec-7th-en-elasticsearch-holiday-proof-your-cluster/110195/1 "2017-12-06T13:00:07Z")

</div>

Before you take off for your well-deserved holidays, here are some tips on how to avoid being rudely pulled back by a pager alert.

**Make sure you set minimum\_master\_nodes**  
To prevent a split brain, check you have set `discovery.zen.minimum_master_nodes` in your `elasticsearch.yml`. In a typical cluster with three master-eligible (or dedicated master) nodes, this setting should be set to 2. See the [`minimum_master_nodes` documentation](https://www.elastic.co/guide/en/elasticsearch/reference/6.0/important-settings.html#minimum_master_nodes).

**Check your JVM heap size**  
Elasticsearch is using two types of memory: The JVM heap, the size of which is set explicitly, and the file system cache, which is set implicitly (all the memory not assigned to the JVM). What memory you assign to the JVM cannot be used by the cache, so it should be as low as possible, and definitely not above 30.5 GB. Read the classic ["A Heap of Trouble"](https://www.elastic.co/blog/a-heap-of-trouble) blog post on this topic to learn more.

**Keep your shards in line**  
A cluster is only as healthy as its shards. In general, you want to have as few shards as you can get away with. Well-sized shards are usually at least a few gigabytes large. To control your shard size, look to the [`number_of_shards` index setting](https://www.elastic.co/guide/en/elasticsearch/reference/6.0/indices-create-index.html), as well as the total number of indices in your cluster.

**Enable Monitoring**  
And lastly, if you're not using it yet, you should: X-Pack Monitoring is free and collects invaluable information about your cluster. Head over to [the download page to install X-Pack](https://www.elastic.co/downloads/x-pack), and get your free license [here](https://register.elastic.co/) if you don't have one already.

And with that, I wish you a happy (and hopefully alert-free) holiday season! 🎄🎉

---

<div class="post-metadata">

**Author:** ![zezz](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/zezz/32/17169_2.png) [@zezz](https://discuss.elastic.co/u/zezz)\
**Post date:** [December 8, 2017, 7:45pm UTC](https://discuss.elastic.co/t/dec-7th-en-elasticsearch-holiday-proof-your-cluster/110195/2 "2017-12-08T19:45:05Z")

</div>

May I add: check your disk 💾 occupancy!

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [August 23, 2018, 8:31am UTC](https://discuss.elastic.co/t/dec-7th-en-elasticsearch-holiday-proof-your-cluster/110195/3 "2018-08-23T08:31:22Z")

</div>


