I've succesfully installed elasticsearch in single-node on Jelastic cloud here is my elastichearch.yml for single-node
network.host: 0.0.0.0
discovery.type: single-node
But When I try to run it in cluster mode, whatever I edited elastichearch.yml for cluster mode I get Connection refused when doing curl my_ip:9200
I can't find any totorial on how to get it to work on Jelastic cloud platform. I followed many totorials for setting up elasticsearch.yml for cluster in other platforms with the same error "Connection refused"
here is a sample of elasticsearch.yml of master node
cluster.name: myCluster
node.name: ESNode1
node.master: true
node.data: true
#network.host: 10.103.1.121
#xpack.security.enabled: false
#http.host: 10.103.1.121
http.port: 9200
discovery.zen.ping.multicast.enabled: true
discovery.zen.ping.unicast.hosts: ["10.103.1.121:9300", "10.103.2.62:9300"]
discover.zen.ping.timeout: 20s
transport.port: 9300
#cluster.initial_master_nodes: node-1
#discovery.seed_hosts: ["10.103.1.121"]
here is a sample of elasticsearch.yml of slave node
cluster.name: myCluster
node.name: ESNode2
node.master: false
node.data: true
#network.host: 10.103.1.121
#xpack.security.enabled: false
#http.host: 10.103.1.121
http.port: 9200
discovery.zen.ping.multicast.enabled: true
discovery.zen.ping.unicast.hosts: ["10.103.1.121:9300", "10.103.2.62:9300"]
discover.zen.ping.timeout: 20s
transport.port: 9300
#cluster.initial_master_nodes: node-1
#discovery.seed_hosts: ["10.103.1.121"]
question from:https://stackoverflow.com/questions/65645318/how-to-setup-elasticsearch-cluster-on-jelastic-got-connection-refused