5

I am moving from elasticsearch 2.x to 5.x and facing this problem while starting up.

[2017-02-28T14:38:24,490][INFO ][o.e.b.BootstrapChecks    ] [node1] bound or publishing to a non-loopback or non-link-local address, enforcing bootstrap checks
[2017-02-28T14:38:24,494][ERROR][o.e.b.Bootstrap          ] [node1] node validation exception
bootstrap checks failed
max file descriptors [8192] for elasticsearch process is too low, increase to at least [65536]
max size virtual memory [52729364480] for user [elastic] is too low, increase to [unlimited]
max virtual memory areas vm.max_map_count [65530] is too low, increase to at least [262144]

My yml looks as follows

node.name:  node1
network.host: _global_

I have downloaded the elasticsearch tarball and OS is SLES11Sp4

Elasticsearch bootstrap checks are defined here. But after playing around with /etc/security/limits.conf and /etc/sysctl.conf, still i cant bring it up.

In rpm installation, these things are supposedly taken care automatically.

4 Answers 4

5

This is the setting which finally worked.

/etc/security/limits.conf

* hard memlock unlimited
* soft memlock unlimited
* hard nofile 65536
* soft nofile 65536
*  - as unlimited

/etc/sysctl.conf

fs.file-max = 2097152
vm.max_map_count = 262144
vm.swappiness = 1

elasticsearch.yml

cluster.name: atul-es-kerberos
node.name:  node1
network.host: _eth0:ipv4_
discovery.zen.ping.unicast.hosts: ["atul.labs.com"]
discovery.zen.minimum_master_nodes: 1
5

max virtual memory areas vm.max_map_count [65530] is too low, increase to at least [262144]

1. Linux

The vm.max_map_count=262144 setting should be set permanently in /etc/sysctl.conf

grep vm.max_map_count /etc/sysctl.conf

vm.max_map_count=262144

OR

sysctl -w vm.max_map_count=262144

1
1

For Docker on Windows, you should:

docker-machine ssh
sudo sysctl -w vm.max_map_count=262144
1
  • 1
    there's no docker-machine on the most recent versions of docker for windows. Instead, you need to use wsl -d docker-desktop in order to invoke sysctl
    – Badashi
    Jul 30, 2020 at 14:11
1

If you are running docker using Colima on macOS you need to ssh into the VM to set the max_map_count parameter as follows

colima ssh
sudo sysctl -w vm.max_map_count=262144

Your Answer

Reminder: Answers generated by Artificial Intelligence tools are not allowed on Stack Overflow. Learn more

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.