Elasticsearch memory problems

前端 未结 5 2022
我寻月下人不归
我寻月下人不归 2020-12-23 12:50

When I\'m trying too start the elasticsearch in my Ubuntu the startup script gives me the following error:

Java HotSpot(TM) Client VM warning: INFO: os::comm         


        
相关标签:
5条回答
  • 2020-12-23 12:58

    For the current version of elastic (5.X) you can configure jvm startup options in the jvm.options file usually located under directory /etc/elasticsearch/jvm.options:

    -Xms1g -Xmx1g
    

    Hope it helps.

    0 讨论(0)
  • 2020-12-23 13:04

    In windows you can edit C:\ProgramData\Elastic\ElastiSearch\config\jvm.option file to change the size of JVM Heap (arguments: -Xms15g -Xmx15g), reducing the memory consumption.

    0 讨论(0)
  • 2020-12-23 13:05

    You have configured a virtual machine with 1 GB of RAM, but elastic is trying to start with 2 GB of RAM (default for Elasticsearch version 5.X)

    Either give more memory to your VM, or change Elasticsearch JVM settings /etc/elasticsearch/jvm.options and lower the values of the following parameters: -Xms512m -Xmx512m

    0 讨论(0)
  • 2020-12-23 13:12

    Ideally elastic search jvm needs more memory for faster processing and querying multiple shards. However, the jvm size should not be more than the system memory size. Change the memory for elastic search as per your configuration in

    /etc/elasticsearch/jvm.options:

    -Xms4g (Minimum memory) -Xmx4g (Maximum memory)

    Set it to the exactly half of the machine memory for ideal use

    0 讨论(0)
  • 2020-12-23 13:18

    You need to start elasticsearch by the following parameters: ./bin/elasticsearch -Xmx512m -Xms512

    However it seems your memory (1G) is too low for running elasticsearch.

    0 讨论(0)
提交回复
热议问题