es单机版尝试(一)

es部署零零散散遇到很多问题,期间有三个问题耗时较久值得回味:

[1]: max number of threads [1024] for user [uapm] is too low, increase to at least [4096]

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

[3]: system call filters failed to install; check the logs and fix your configuration or disable system call filters at your own risk

问题3容易解决,解决:yml文件中添加配置bootstrap.system_call_filter: false

问题2也比较容易,是因为操作系统的vm.max_map_count参数设置太小导致的,使用root用户登录系统,执行以下命令:

sysctl -w vm.max_map_count=262144

并用以下命令查看是否修改成功

sysctl -a | grep “vm.max_map_count”

如果能正常输出262144,则说明修改成功

问题1很棘手,查了好久 最终通过如下命令成功解决

[[email protected] /]# vim /etc/security/limits.d/90-nproc.conf

[[email protected] /]# su uapm

[[email protected] /]$ ulimit -a

查看进程:

[[email protected] bin]$ ps -ef | grep elas

uapm 3194 3069 0 17:55 pts/0 00:00:00 grep elas

杀死进程:

[[email protected] /]$ kill -9 3069

Killed 之后重新启动即可

es单机版尝试(一)

 

 

同时遇到启动程序报错:

Java HotSpot(TM) 64-Bit Server VM warning: INFO: os::commit_memory(0x00000006fff80000, 2863661056, 0) failed; error=’Cannot allocate memory’ (errno=12)

#

There is insufficient memory for the Java Runtime Environment to continue. # Native memory allocation (malloc) failed to allocate 2863661056 bytes for committing reserved memory. # An error report file with more information is saved as: # /home/raini/IdeaProjects/spark_mllib/hs_err_pid19206.log

内存不足: 减少启动程序所需内存,或加大内存,如关闭一些程序。

解决方案:

es单机版尝试(一)

 

小编也是新人,记录点滴~