Suppose, I have 2 virtual machines (4 core, 8 gb RAM, CentOS each).
According to elasticsearch's documentation, half of RAM should be allocated to elasticsearch. So, this is what I came up with:
Node1: Elasticsearch Master n Data node with 4 gb HEAP (server1)
Node2: Elasticsearch Master Only(no data) node with 1 gb HEAP (server1)
Node3: Elasticsearch Master n Data node with 4 gb HEAP (server2)
Now, why I want to deploy 3 nodes on 2 servers? Because I want to avoid the Split Brains problem.
Is this is a sane strategy? Or can there be a better clustering strategy? Moreover, if I remove Master Only node (Node2) from my load balancer i.e. any request of search / insert / update / delete will not be sent to it, will it still require 1 gb HEAP?