I do know it's better to have separate server for each job, but I have a shared server between Elasticsearch and MySQL, with a total 8 Gig RAM.
we should avoid swapping in Elasticsearch, so I set bootstrap.memory_lock: true
, and I need to set/uncomment MAX_LOCKED_MEMORY=unlimited
in file /etc/default/elasticsearch
.
Question : Do I have to set this to unlimited while we know that only 4G must be assigned to Elasticsearch? How do I set MAX_LOCKED_MEMORY
to 4G for example and not to unlimited? cause I have 8G shared memory between Elasticsearch and MySQL, and is this true in this case to set it to 4G instead of unlimited? If not, what's the best configuration? I think it should be something like this maybe:
MAX_LOCKED_MEMORY= 4G