After doing this, lets say i bring up node10 without any cluster name in the config but it has ip of node1 in its mesh-seed-address-port. will this node be able to join the cluster? Or I need to make sure the new node10 has clustername set to “cluster1”?
A node with a non-matching cluster name cannot join a cluster. So in your scenario, you must assign the same cluster name to the new node that you want the node to be part of.
Then i have another questions. Initially when there was no cluster name in any node (node1,2,3). And I assigned cluster name to node1, how would node2 and node 3 accept node1? as their cluster name is diff than node1. how is this diff from node10 trying to join the cluster.
It has to do with how nodes determine cluster membership using heartbeat messages they exchange with all other nodes. A heartbeat from a node with a different cluster name is not accepted, and if certain number of valid heartbeats are missed from a node, it is removed from the cluster. Typically a node will be removed from the cluster in less than a couple of seconds without valid heartbeats.
When you change the cluster name in all nodes (nodes 1, 2, and 3 in your example), the operation takes effect across all nodes within a fraction of second. Therefore, all nodes continue to exchange valid heartbeats (with the new cluster name)., and remain part of the same cluster
However a new node (node 10 in your example) cannot join a cluster unless it can send the valid cluster name in its heartbeat message to the other nodes.
Yes, that’s correct, the original doc needs to be updated.
Since you want the cluster operation unaffected, all nodes should be updated almost simultaneously. You can do so with asadm that issues the command to all nodes. This should work unless something gets in the way of some nodes from getting the info command. So just to be extra safe, you could also either disable heartbeat or increase the heartbeat interval before issuing the cluster name change, and then revert to the prior heartbeat setting afterwards.