记录启动ElasticSearch的出现的问题

java.lang.RuntimeException: can not run elasticsearch as root

原因:为了安全起见不能以root用户启动 解决方法:单独为elasticsearch创建一个新的用户

java.lang.UnsupportedOperationException: seccomp unavailable: CONFIG_SECCOMP not compiled into kernel, CONFIG_SECCOMP and CONFIG_SECCOMP_FILTER are needed

在所有节点的elasticsearch.yml配置文件中加入:

bootstrap.memory_lock: false

bootstrap.system_call_filter: false

memory locking requested for elasticsearch process but memory is not locked

编辑 /etc/security/limits.conf 添加如下内容:

* soft nofile 65536

* hard nofile 65536

* soft memlock unlimited

* hard memlock unlimited

备注:* 代表Linux所有用户名称

max number of threads [2048] for user [es] is too low, increase to at least [4096]

编辑 vim /etc/security/limits.d/90-nproc.conf

从2048改为4096

* soft nproc 4096

备注:* 代表Linux所有用户名称

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

编辑 /etc/sysctl.conf,添加如下内容,执行sysctl -p后生效

vm.max_map_count=262144

转载于:https://my.oschina.net/kdy1994/blog/3095687

你可能感兴趣的:(记录启动ElasticSearch的出现的问题)