I believe that If no cluster exists then the first node which will start will read this value from elasticsearch.yml.
With that the cluster state will be created.
When a new node starts, it uses the values available in the cluster state.
I did not check the code or tested it so I could be wrong though.
But for settings starting with node., those are read by the node when it starts.
It means that those settings are local to the node.
I found following description in the official document:
The master node is responsible for lightweight cluster-wide actions such as creating or deleting an index, tracking which nodes are part of the cluster, and deciding which shards to allocate to which nodes.
I think it's the master to decide the cluster setting.
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.