3个异常如下:
[1]: max file descriptors [65535] for elasticsearch process is too low, increase to at least [65536][2]: memory locking requested for elasticsearch process but memory is not locked[3]: max virtual memory areas vm.max_map_count [65530] is too low, increase to at least [262144]
[1]: max file descriptors [65535] for elasticsearch process is too low, increase to at least [65536]
切换到root用户,编辑limits.conf 添加类似如下内容 vim /etc/security/limits.conf 添加如下内容:* soft nofile 262144* hard nofile 262144
wenti2我没遇到
[2]: memory locking requested for elasticsearch process but memory is not locked
原因:锁定内存失败解决方案:
切换到root用户,编辑limits.conf配置文件, 添加类似如下内容:sudo vim /etc/security/limits.conf添加如下内容:* soft memlock unlimited
* hard memlock unlimited备注:* 代表Linux所有用户名称保存、退出、重新登录才可生效
问题3
[3]: max virtual memory areas vm.max_map_count [65530] is too low, increase to at least [262144]
原因:最大虚拟内存太小
解决方案:切换到root用户下,修改配置文件sysctl.confsudo vim /etc/sysctl.conf添加下面配置:vm.max_map_count=655360并执行命令:sysctl -p