ElasticSearch 学习之 bootstrap checks failed

问题

启动失败,日志:

[3] bootstrap checks failed
[1]: max file descriptors [4096] for elasticsearch process is too low, increase to at least [65535]
[2]: max number of threads [3795] for user [es] is too low, increase to at least [4096]
[3]: max virtual memory areas vm.max_map_count [65530] is too low, increase to at least [262144]

分析+解决

  • [1]: max file descriptors [4096] for elasticsearch process is too low, increase to at least [65535]

系统为elasticsearch进程分配的最大可用文件描述符4096不够用,至少分配65535个。

增加配置命令:ulimit -n 65535

  • [2]: max number of threads [3795] for user [es] is too low, increase to at least [4096]

系统为es用户分配的最大可用线程数3795太少,至少分配4096个。

增加线程数: ulimit -u 4096

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

内核参数:最大虚拟内存65530太少,至少分配262144

执行命令:sysctl -w vm.max_map_count=262144

你可能感兴趣的:(ElasticSearch)