问题出现环境,OS版本:CentOS-7-x86_64-Minimal-1708;ES版本:elasticsearch-6.2.2。java
一、max file descriptors [4096] for elasticsearch process is too low, increase to at least [65536]jvm
每一个进程最大同时打开文件数过小,可经过下面2个命令查看当前数量elasticsearch
ulimit -Hn
ulimit -Sn
修改/etc/security/limits.conf文件,增长配置,用户退出后从新登陆生效spa
* soft nofile 65536
* hard nofile 65536
二、max number of threads [3818] for user [es] is too low, increase to at least [4096]线程
问题同上,最大线程个数过低。修改配置文件/etc/security/limits.conf(和问题1是一个文件),增长配置code
* soft nproc 4096
* hard nproc 4096
可经过命令查看blog
ulimit -Hu
ulimit -Su
修改后的文件:进程
三、max virtual memory areas vm.max_map_count [65530] is too low, increase to at least [262144]ip
修改/etc/sysctl.conf文件,增长配置vm.max_map_count=262144it
vi /etc/sysctl.conf
sysctl -p
执行命令sysctl -p生效
四、Exception in thread "main" java.nio.file.AccessDeniedException: /usr/local/elasticsearch/elasticsearch-6.2.2-1/config/jvm.options
elasticsearch用户没有该文件夹的权限,执行命令
chown -R es:es /usr/local/elasticsearch/