文章基于elasticsearch单节点启动异常汇总基础上,进行多台机器配置。
修改elasticsearch.yml
1:去掉单节点类型申明:
#discovery.type: single-node
2:增加机器节点:
discovery.seed_hosts: ["120.77.XX.XXX", "120.76.XX.XXX","120.76.XX.XXX"]
3:由于elasticsearch使用的是7.x版本
或者出现如下异常信息:max virtual memory areas vm.max_map_count [65530] is too low, increase to at least [262144]
需要修改最大虚拟内存:
修改配置文件/etc/sysctl.conf,修改内容如下:
vim /etc/sysctl.conf
添加下面配置:
vm.max_map_count = 262144
执行文件生效指令:
sysctl -p
出现如下异常信息:max number of threads [1024] for user [elsearch] is too low, increase to at least [2048]
修改/etc/security/limits.d/90-nproc.conf配置文件,修改内容如下:
vim /etc/security/limits.d/90-nproc.conf
- soft nproc 1024
#修改为- soft nproc 2048
分别启动三台机器,最后可在elsticHD中看到:
0评论