一、安装启动篇
1.“can not run elasticsearch as root”;
es5.0版本后要求非root用户登录,必须创建新用户如es
(1)创建用户:adduser es
(2)创建用户密码: passwd es
2.“could not find java in JAVA_HOME at …”;
最好jdk和es都别装在root目录下,不然启动可能会找不到JAVA_HOME
3.“AccessDeniedException”;
必须给新的用户es赋权,
chown -R es elasticsearch-7.16.1
4.“Future versions of Elasticsearch will require Java 11”
使用jdk至少为11
5.“max number of threads [1024] for user [es] is too low, increase to at least [4096]”
vi /etc/security/limits.d/90-nproc.conf
-
soft nproc 4096
将1024改为4096,修改完需要重新登录用户,配置才能生效
6.“bootstrap check failure [3] of [5]: max virtual memory areas vm.max_map_count [65530] is too low, increase to at least [262144]”
vi /etc/security/limits.conf
添加下面两行,修改完需要重新登录用户,配置才能生效
- soft nofile 65536
- hard nofile 65536
7.“max virtual memory areas vm.max_map_count [65530] is too low, increase to at least [262144]”
vi /etc/sysctl.conf
添加下面一行
vm.max_map_count=262144
执行 /sbin/sysctl -p,配置才能生效
8.“system call filters failed to install; check the logs and fix your configuration or disable system call filters at your own risk”
修改elasticsearch.yml找到#bootstrap.memory_lock:true,在下面添加下面两行
bootstrap.memory_lock: false
bootstrap.system_call_filter: false
9.“java.lang.UnsupportedOperationException: seccomp unavailable: CONFIG_SECCOMP not compiled into kernel, CONFIG_SECCOMP and CONFIG_SECCOMP_FILTER are needed”
修改方法同上
二、应用篇(待续)
last:如果真的帮您解决问题了,请点个赞吧。还有什么待补充的,可以下面留言。
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)