ELK安装问题
错误日志:
[2018-07-30T18:18:22,438][ERROR][o.e.b.Bootstrap ] [es-2] node validation exception
[2] bootstrap checks failed
[1]: max file descriptors [65535] for elasticsearch process is too low, increase to at least [65536]
[2]: max virtual memory areas vm.max_map_count [65530] is too low, increase to at least [262144]
[2018-07-30T18:18:22,443][INFO ][o.e.n.Node ] [es-2] stopping ...
[2018-07-30T18:18:22,471][INFO ][o.e.n.Node ] [es-2] stopped
[2018-07-30T18:18:22,472][INFO ][o.e.n.Node ] [es-2] closing ...
[2018-07-30T18:18:22,485][INFO ][o.e.n.Node ] [es-2] closed
1
2
3
4
5
6
7
8
2
3
4
5
6
7
8
原因: 文件句柄不足,设定虚拟内存不足
解决方法:
切换到root用户下
调整文件句柄数: 修改limits.conf文件,修改以下内容:vi /etc/security/limits.conf
soft nofile 65536
hard nofile 65536
soft nproc 10240
hard nproc 10240
1
2
3
4
5
6
7
2
3
4
5
6
7
调整虚拟内存权限: 临时生效:sysctl -w vm.max_map_count=262144 查看结果:sysctl -a|grep vm.max_map_count
永久生效:修改sysctl.conf文件,添加以下内容:vi /etc/sysctl.conf vm.max_map_count=655360
使配置生效:sysctl -p
启动命令: /home/jyapp/elasticsearch-6.3.2/bin/elasticsearch -d
上次更新: 2022/06/12, 15:48:09