I have a cluster of 3 nodes. I need to change a setting in elasticsearch.yml and then restart the cluster. I am a bit confused on the procedure. Here is what I have so far. Is this correct?
Make changes to /etc/elasticsearch/elasticsearch.yml on all 3 nodes in the cluster.
On the master node only, run sudo service elasticsearch restart
Is this all there is to it? Or do I need to also run commands on the child nodes as well?
If you have 3 master eligible nodes you can perform a rolling restart without any outage because stopping one node at the time you will keep the quorum (2 out of 3).
There is two way you can do.
shutdown whole cluster and restart, if you can afford stopping ingestion
execute this on all three nodes
systemctl stop kibana
systemctl stop logstash
then stop elasticsearch simultaniously
systemctl stop elasticsearch
and then start in reverse.
otherwise one node at a time(rolling update). but on this procedure don't forget to disable shard reallocation for faster restaart. make sure your cluster is green before you stop/start second node.
I assumed that the presence of an asterisk * indicated that it's the master. Is that not the case?
Or does it indicate that all nodes are master-eligible and have chosen es-oc2-q03 node to be master via the quorum?
Does it change anything with regards to the running the commands you outlined? Meaning, the order of the nodes on which I run them?
all nodes are master nodes. but q03 is taking lead. hence if you shutdown that automatically another will take lead. and that will have *.
process is completely random.
I had three node cluster for long time and I did upgrade/update by shutting down everything and starting all.
order is does not matter here because you shutting down all services.
now I have larger cluster and I now do rolling upgrade/update it takes little longer that is it.
In this process as well no order matter.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.