Cheat Sheet

Sunday, March 5, 2017

Elasticsearch 5.2 on CentOS 7: ERROR: bootstrap checks failed

Previously, got this error:

ERROR: bootstrap checks failed
max file descriptors [4096] for elasticsearch process is too low, increase to at least [65536]
max number of threads [1024] for user [username] is too low, increase to at least [2048]
max virtual memory areas vm.max_map_count [65530] is too low, increase to at least [262144]

So what I do is:

vi /etc/security/limits.conf

# Add or edit
* soft nofile 65536
* hard nofile 131072
* soft nproc 2048
* hard nproc 4096
#EOF /etc/security/limits.conf
 
vi /etc/security/limits.d/90-nproc.conf

# changed original soft nproc 1024 to 2048
#*          soft    nproc     1024
*          soft    nproc     2048
#EOF /etc/security/limits.d/90-nproc.conf

 
vim /etc/sysctl.conf

# Added here
vm.max_map_count = 262144
#EOF /etc/sysctl.conf
 
sysctl -p


No comments:

Post a Comment