es7.13.2集群安装失败报错处理

ERROR: 2 bootstrap checks failed.You must address the points described in the following 2 lines before starting Elasticsearch.

bootstrap checks failed 1 of 2: memory locking requested for elasticsearch process but memory is not locked

bootstrap checks failed 1 of 2: max virtual memory areas vm.max_map_count 65530 is too low, increase to at least 262144

ERROR: Elasticsearch did not exit normally - check the logs at /a/es/logs/my-cluster.log

系统:centos7.6 (vm虚拟机)

软件:java-1.8、elasticsearch-5.6.16-1.noarch

错误信息:

2019-11-21T00:29:51,557ERRORo.e.b.Bootstrap elk-1 node validation exception

1 bootstrap checks failed

1: memory locking requested for elasticsearch process but memory is not locked

解决方法一(关闭bootstrap.memory_lock:,会影响性能):

vim /etc/elasticsearch/elasticsearch.yml // 设置成false就正常运行了。

bootstrap.memory_lock: false

解决方法二(开启bootstrap.memory_lock:):

  1. 修改文件/etc/elasticsearch/elasticsearch.yml,上面那个报错就是开启后产生的,如果开启还要修改其它系统配置文件

bootstrap.memory_lock: true

  1. 修改文件/etc/security/limits.conf,最后添加以下内容。
bash 复制代码
vim /etc/security/limits.conf 
bash 复制代码
* soft nofile 65536

* hard nofile 65536

* soft nproc 32000

* hard nproc 32000

* hard memlock unlimited

* soft memlock unlimited
  1. 修改文件 /etc/systemd/system.conf ,分别修改以下内容。
bash 复制代码
DefaultLimitNOFILE=65536

DefaultLimitNPROC=32000

DefaultLimitMEMLOCK=infinity

改好后重启下系统。再启动elasticsearch就没报错了 。

bash 复制代码
vim /etc/sysctl.conf

保存文件并执行以下命令使修改生效:

bash 复制代码
   sysctl -p

es7.13.2启动报错:

bootstrap checks failed 1 of 2: max virtual memory areas vm.max_map_count 65530 is too low, increase to at least 262144

bash 复制代码
vim /etc/sysctl.conf

vm.max_map_count=262144

 sysctl -p
相关推荐
Championship.23.242 小时前
Linux 3.0 锁机制与故障排查详解
linux·运维·服务器
风123456789~4 小时前
【Linux专栏】ls 排除某个文件
linux·运维·服务器
其实防守也摸鱼5 小时前
运维--学习阶段问题解答(1)(自测)
linux·运维·服务器·数据库·学习·自动化·命令模式
Darkwanderor7 小时前
对Linux的进程控制的研究
linux·运维·c++
爱网络爱Linux10 小时前
Linux proc 目录安全加固
linux·运维·rhce·rhca·红帽认证·proc 目录安全加固
MindUp10 小时前
企业网盘权限模型解析:多层级访问控制与审计能力选型指南
java·linux·运维
持力行10 小时前
D-BUS会话总线
运维·网络
kdxiaojie10 小时前
Linux 驱动研究 —— I2C (5)
linux·运维·笔记·学习
独自归家的兔11 小时前
2026年7月2日 Docker 容器化部署 PaddleOCR-VL 实战(OpenAI 协议兼容 HTTP 调用)
运维·docker·容器
ZXXstarstar11 小时前
2026年电池安全使用年限的量化决策:什么时间到期最需要替换?
linux·运维·服务器·电池