Set target nodes where shards are created to?


(Jason Y) #1

hello,
i have one question about shard location.

Situation:
we do have currently 6data nodes as 6 VMs (virtual machine) on 3 actual hosts(each host currently have 1 hot node and 1warm node). we are planning to add 52 data nodes by adding 13 actual hosts (each host will have 2 hot and 2warm nodes; 2213=52).
currently we set primary=5 & replica=1, and would continue with this setting. but concern is if some shards are located in a specific host duplicately, then that host is down.
_e.g. _
vm1(host1): p0
vm2(host1): p1, r0
...
vm7(host4): r1
...
vm9(host5): p3
vm10(host5): p2,r4
...
vm16(host08): p5
...
vm28(host14):r2
...
vm32(host16):r3
...

in case the host01 server is down, we will lose p0, p1 and r0 shards, then there are no primary nor replicas to recover. they are not on the same node, so this scenario is possible. right?

Question:

  • can we set target nodes where the shards should be created? or should not be created? if so, is it possible that behavior works automatically?

if my understanding or question was wrong, please correct me.

thank you!


(David Turner) #2

Shard allocation awareness sounds like the feature you are looking for.


(Jason Y) #3

wow! you guys are awesome! thank you!


(system) #4

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