Cluster elasticsearch port

I want to set up a 3-node elasticsearch cluster in production.
2 nodes master & data and one voting-only or data.
I would like to know if I can assign a single port per node and not a range.
For example : node1 port 9201 and 9301
node2 port 9202 and 9302
node3 port 9203 and 9303

It's possible?
Does it interfer the communication between nodes in cluster? Does it facilitate their discovery?
What are the best practices for this?

Best regards,

You can do this, but you will need to manually configure each ip/hostname and port.

Why do you want to do this though?

To have only the necessary ports open and better identify them.
Does this complicate the configuration?
Do you have any recommendations?

Thank you for your answer @warkolm

I would just use the standards, then you only have 2 ports to worry about.

Okay, thanks for the advice @warkolm
Another question is it interesting to have 2 logstash servers with each one a pipeline if the number of logs to process is important?
Should the port be different on both servers?
logstash1 9601, logstash2 9602

And can kibana be present at the same time as elasticsearch on node3 for example which is a data node?

Thanks again

There's really no reason to change the port numbers unless you are being forced to do so, or you are running multiple instances of something on the same host.

There is a reason: everybody knows that ES uses 9200. My cluster uses other ports - above 10000. Same port for every ES node in cluster.

My firewall accepts incoming traffic only from ip of my nodes with specific ports. Same I did with my Kibana, Filebeat, Logstash, etc. - not even one of them uses the default port.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.