美文网首页
ERROR: Elasticsearch did not exi

ERROR: Elasticsearch did not exi

作者: 一位先生_ | 来源:发表于2023-04-03 17:06 被阅读0次

ERROR: [1] bootstrap checks failed
[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
ERROR: Elasticsearch did not exit normally - check the logs at /usr/share/elasticsearch/logs/docker-cluster.log

标题解决办法:
启动的时候创建专有网络

docker network create esnet
docker run --name es  -p 9200:9200 -p 9300:9300  --network esnet -e "discovery.type=single-node"  镜像id

注意:
你这里启动es容器使用了专有网络,所以启动kibana和logstash等也需要使用专有网络 不然会和es建立不了连接(因为专有网络问题)
如:kibana
原:

docker run --name kibana -e ELASTICSEARCH_URL=http://127.0.0.1:9200 -p 5601:5601 -d 镜像名

现需要调整为:

docker run --name kibana -e ELASTICSEARCH_URL=http://127.0.0.1:9200 -p 5601:5601  --network esnet -e "discovery.type=single-node"  docker镜像id

相关文章

网友评论

      本文标题:ERROR: Elasticsearch did not exi

      本文链接:https://www.haomeiwen.com/subject/ytqjddtx.html