Hello good afternoon.
Friends, excuse me, I'm trying to do a docker, but it's throwing an error at me.
this is the docker-compose.yml
version: '2.2'
services:
es01:
image: docker.elastic.co/elasticsearch/elasticsearch:7.3.2
container_name: es01
privileged: true
hostname: es01
extra_hosts:
- "es01:172.20.0.2"
- "es02:172.20.0.3"
- "es03:172.20.0.4"
environment:
- cluster.name=cluster
- node.name=es01
- network.host=es01
- http.port=9200
- transport.host=localhost
- transport.port=9300
- discovery.seed_hosts=es01,es02,es03
- cluster.initial_master_nodes=es01
- node.master=true
- node.voting_only=false
- node.data=false
- node.ingest=false
- node.ml=false
- xpack.ml.enabled=true
- cluster.remote.connect=false
- bootstrap.memory_lock=true
- "ES_JAVA_OPTS=-Xms512m -Xmx512m -Des.transport.cname_in_publish_address=true"
ulimits:
memlock:
soft: -1
hard: -1
volumes:
- /home/user/docker/data01:/usr/share/elasticsearch/data
ports:
- 9200:9200
- 9300:9300
networks:
elastic:
ipv4_address: 172.20.0.2
es02:
image: docker.elastic.co/elasticsearch/elasticsearch:7.3.2
container_name: es02
privileged: true
hostname: es02
extra_hosts:
- "es01:172.20.0.2"
- "es02:172.20.0.3"
- "es03:172.20.0.4"
environment:
- cluster.name=cluster
- node.name=es02
- network.host=es02
- http.port=9200
- transport.host=localhost
- transport.port=9300
- discovery.seed_hosts=es01,es02,es03
- cluster.initial_master_nodes=es01
- node.master=true
- node.voting_only=false
- node.data=true
- node.ingest=true
- node.ml=false
- xpack.ml.enabled=true
- cluster.remote.connect=false
- bootstrap.memory_lock=true
- "ES_JAVA_OPTS=-Xms512m -Xmx512m"
ulimits:
memlock:
soft: -1
hard: -1
volumes:
- /home/user/docker/data02:/usr/share/elasticsearch/data
ports:
- 9201:9200
- 9301:9300
networks:
elastic:
ipv4_address: 172.20.0.3
es03:
image: docker.elastic.co/elasticsearch/elasticsearch:7.3.2
container_name: es03
privileged: true
hostname: es03
extra_hosts:
- "es01:172.20.0.2"
- "es02:172.20.0.3"
- "es03:172.20.0.4"
environment:
- cluster.name=cluster
- node.name=es03
- network.host=es03
- http.port=9200
- transport.host=localhost
- transport.port=9300
- discovery.seed_hosts=es01,es02,es03
- cluster.initial_master_nodes=es01
- node.master=true
- node.voting_only=false
- node.data=true
- node.ingest=true
- node.ml=false
- xpack.ml.enabled=true
- cluster.remote.connect=false
- bootstrap.memory_lock=true
- "ES_JAVA_OPTS=-Xms512m -Xmx512m"
ulimits:
memlock:
soft: -1
hard: -1
volumes:
- /home/user/docker/data03:/usr/share/elasticsearch/data
ports:
- 9202:9200
- 9302:9300
networks:
elastic:
ipv4_address: 172.20.0.4
volumes:
data01:
driver: local
data02:
driver: local
data03:
driver: local
networks:
elastic:
ipam:
config:
- subnet: 172.20.0.0/24
ip_range: 172.20.0.0/24
I have made a lot of arrangements, but I do not understand why it throws me the following error:
es02 | {"type": "server", "timestamp": "2020-03-22T03:29:51,925+0000", "level": "WARN", "component": "o.e.c.c.ClusterFormationFailureHelper", "cluster.name": "cluster", "node.name": "es02", "message": "master not discovered yet, this node has not previously joined a bootstrapped (v7+) cluster, and this node must discover master-eligible nodes [es01] to bootstrap a cluster: have discovered [{es02}{n7LOlgofTK2yxyQdeI5ogA}{_HPlHq5dQ1aANwgvojg5Sw}{localhost}{127.0.0.1:9300}{dim}{xpack.installed=true}]; discovery will continue using [172.20.0.2:9300, 172.20.0.3:9300, 172.20.0.4:9300] from hosts providers and [{es02}{n7LOlgofTK2yxyQdeI5ogA}{_HPlHq5dQ1aANwgvojg5Sw}{localhost}{127.0.0.1:9300}{dim}{xpack.installed=true}] from last-known cluster state; node term 0, last-accepted version 0 in term 0" }
es03 | {"type": "server", "timestamp": "2020-03-22T03:29:52,162+0000", "level": "WARN", "component": "o.e.c.c.ClusterFormationFailureHelper", "cluster.name": "cluster", "node.name": "es03", "message": "master not discovered yet, this node has not previously joined a bootstrapped (v7+) cluster, and this node must discover master-eligible nodes [es01] to bootstrap a cluster: have discovered [{es03}{D9fbndDAR0ar4jq9IDLejA}{0awVC4qZQ_ethGOUgPEziw}{localhost}{127.0.0.1:9300}{dim}{xpack.installed=true}]; discovery will continue using [172.20.0.2:9300, 172.20.0.3:9300, 172.20.0.4:9300] from hosts providers and [{es03}{D9fbndDAR0ar4jq9IDLejA}{0awVC4qZQ_ethGOUgPEziw}{localhost}{127.0.0.1:9300}{dim}{xpack.installed=true}] from last-known cluster state; node term 0, last-accepted version 0 in term 0" }