Allocation awareness - something not right

Agreed. A PR to emphasise which elasticsearch.yml file we're talking about throughout that page would be very welcome.

1 Like

Well I originally had a more complex compound routing awareness, but that didn't work (no surprise, now I understand that the master nodes DO require some config) and switched to this simpler form, but when I was looking at the documentation I did find it ambiguous WRT compound routing awareness would work or not, perhaps that could/should also be reviewed.

Thanks both for your help, I'll confirm next week all good

... well I got chance to do it today....

Early signs are good and the network is going nuts as I'd expect.

So to get rack awareness for my cluster, I am hoping this will work:

Add:

cluster.routing.allocation.awareness.attributes: rackid cluster.routing.allocation.awareness.force.roomid.values: rack1,rack2

to master nodes

and

node.attr.rackid

to data nodes.

rackid? roomid?

So I added extended allocation awareness, goal changed from replica in other room to include any multiple replicas in a different rack.

Masters now have the awareness routing:
======= master1 =======
cluster.routing.allocation.awareness.attributes:
- roomid
- rackid
cluster.routing.allocation.awareness.force.rackid.values: 1-rack1,1-rack2,2-rack1,2-rack2
cluster.routing.allocation.awareness.force.roomid.values: 1,2
=======================
======= master2 =======
cluster.routing.allocation.awareness.attributes:
- roomid
- rackid
cluster.routing.allocation.awareness.force.rackid.values: 1-rack1,1-rack2,2-rack1,2-rack2
cluster.routing.allocation.awareness.force.roomid.values: 1,2
=======================
======= master3 =======
cluster.routing.allocation.awareness.attributes:
- roomid
- rackid
cluster.routing.allocation.awareness.force.rackid.values: 1-rack1,1-rack2,2-rack1,2-rack2
cluster.routing.allocation.awareness.force.roomid.values: 1,2
=======================
Data nodes have Node attributes:

======= node1 =======
node.attr.rackid: 1-rack1
node.attr.roomid: 1
=======================
======= node2 =======
node.attr.rackid: 2-rack1
node.attr.roomid: 2
=======================
======= node3 =======
node.attr.rackid: 1-rack2
node.attr.roomid: 1
=======================
======= node4 =======
node.attr.rackid: 2-rack2
node.attr.roomid: 2
=======================
======= node5 =======
node.attr.rackid: 1-rack1
node.attr.roomid: 1
=======================
======= node6 =======
node.attr.rackid: 2-rack1
node.attr.roomid: 2
=======================
======= node7 =======
node.attr.rackid: 1-rack2
node.attr.roomid: 1
=======================
======= node8 =======
node.attr.rackid: 2-rack2
node.attr.roomid: 2
=======================

All looks good, thank you David and Martin.
1 Like

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