Open desertSniper87 opened 5 months ago
We can change the heap size by editing docker-compose.yml
and passing ES_JAVA_OPTS
environment variable to elasticsearch container.
elasticsearch:
...
environment:
+ - ES_JAVA_OPTS=-Xmx1g -Xms1g
Added a pull request to change the readme https://github.com/peasead/elastic-container/pull/46#issue-2378867303
I think those are legacy docs. If you look you can see it's for version 8.2
.
Looking here at 8.14
(the current version), it says
By default, Elasticsearch automatically sets the JVM heap size based on a node’s roles and total memory. Using the default sizing is recommended for most production environments.
Do you see something that recommends adjusting the heap size in 8.14
?
Also, is this different than what's in the docker-compose.yml
file?
How to increase the JVM heap size from 512m to 1G?
The official docs say this to pass as environment variable
-Xms1g -Xmx1g
: https://www.elastic.co/guide/en/elastic-stack-get-started/current/get-started-stack-docker.html#docker-enroll-nodes