Allocating RAM to Elasticsearch nodes

(Michael) #1

I have a server which that has multiple elasticsearch nodes on it, how do I allocate RAM for each specific node? I used
export ES_HEAP_SIZE=30g for the first node. How do I allocate a specific amount for the second node?


(Magnus Bäck) #2

How are you starting your different instances?

(Michael) #3

I'm wanting them to both have init.d scripts.

(Magnus Bäck) #4

If you use the stock init scripts they'll load the /etc/default (or /etc/sysconfig) file with the same name, i.e. /etc/init.d/elasticsearch-foo loads /etc/default/elasticsearch-foo so just set ES_HEAP_SIZE in the file corresponding to each instance.

(system) #5