at least one of [discovery.seed_hosts, discovery.seed_providers, cluster.initial_master_nodes] must be configured

发表于 2021-07-09
阅读 121

介绍

介绍

福哥在安装Elasticsearch7的时候遇到了问题,报告如下的错误消息:

bootstrap check failure [1] of [1]: the default discovery settings are unsuitable for production use; at least one of [discovery.seed_hosts, discovery.seed_providers, cluster.initial_master_nodes] must be configured

原因

原来这是ES7做的调整,ES7强化了集群功能,即使是一台ES服务器也需要配置集群参数。

解决

discovery.seed_hosts是种子主机列表,就是说集群的主机地址列表,格式为:主机:端口。

discovery.seed_providers也是种子主机列表,只不过是文件方式的。

cluster.initial_master_nodes集群初始化时候的主节点列表。

经过福哥的测试只需要设置cluster.initial_master_nodes就可以了。

cluster.name: "docker-cluster-es7"
node.name: "node-es7"
network.host: 0.0.0.0
http.port: 9200
cluster.initial_master_nodes: ["node-es7"]

就算把自己的node.name放进去就行了~~

鬼谷子叔叔

跟福哥学编程吧~~
日志
212
浏览
1626