Elasticsearch - Dynamic Nodes
Shard (re)allocation using a
standard installation
Scott Davis
Using default elasticsearch.yml
Node-1

Node-2

0

1

2

3

4

0

1

2

3

Node-3

4

Node-4

Node-5

elasticsearch cluste...
“Sane” defaults
• Provide quick and easy ramp up
• Leverage hardware changes over time
• Either on-prem or cloud (EC2)
Advanced settings
Using custom es_allocation.yml
Node-1

Node-2

node.group=replica

node.group=replica

1

2

4

5

Node-5

0

node.group=p...
Default node types
# Allow this node to be eligible as a master node
(enabled by default):
#
# node.master: true
#
# Allow...
Additional node types
# 1. You want this node to never become a master node, only to hold data.
# This will be the "workho...
Using custom es_allocation_adv.yml
SLB-2

SLB-1
Node-1

Node-2

node.group=replica

node.group=replica

1

2

4

5

Node-5...
Additional info
• cluster.routing.allocation.*
• index.routing.allocation.*
• cluster reroute
http://www.elasticsearch.org...
Upcoming SlideShare
Loading in …5
×

Elasticsearch - Dynamic Nodes

1,524 views
1,151 views

Published on

Shard (re)allocation using a standard installation of Elasticsearch, as well as a couple of advanced examples.

Published in: Technology
0 Comments
1 Like
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total views
1,524
On SlideShare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
10
Comments
0
Likes
1
Embeds 0
No embeds

No notes for slide

Elasticsearch - Dynamic Nodes

  1. 1. Elasticsearch - Dynamic Nodes Shard (re)allocation using a standard installation Scott Davis
  2. 2. Using default elasticsearch.yml Node-1 Node-2 0 1 2 3 4 0 1 2 3 Node-3 4 Node-4 Node-5 elasticsearch cluster index.number_of_shards: 5 index.number_of_replicas: 1 http.port: 9200 transport.tcp.port: 9300 discovery.zen.ping.multicast.enabled: true
  3. 3. “Sane” defaults • Provide quick and easy ramp up • Leverage hardware changes over time • Either on-prem or cloud (EC2)
  4. 4. Advanced settings
  5. 5. Using custom es_allocation.yml Node-1 Node-2 node.group=replica node.group=replica 1 2 4 5 Node-5 0 node.group=primary 1 node.group=replica 3 Node-4 0 Node-3 node.group=primary 2 3 4 5 elasticsearch cluster index.number_of_shards: 6 index.number_of_replicas: 1 cluster.routing.allocation.awareness.attributes: group
  6. 6. Default node types # Allow this node to be eligible as a master node (enabled by default): # # node.master: true # # Allow this node to store data (enabled by default): # # node.data: true
  7. 7. Additional node types # 1. You want this node to never become a master node, only to hold data. # This will be the "workhorse" of your cluster. # # node.master: false # node.data: true # # 2. You want this node to only serve as a master: to not store any data and # to have free resources. This will be the "coordinator" of your cluster. # # node.master: true # node.data: false # # 3. You want this node to be neither master nor data node, but # to act as a "search load balancer" (fetching data from nodes, # aggregating results, etc.) # # node.master: false # node.data: false
  8. 8. Using custom es_allocation_adv.yml SLB-2 SLB-1 Node-1 Node-2 node.group=replica node.group=replica 1 2 4 5 Node-5 node.group=primary 1 node.group=replica 3 Node-4 0 Node-3 node.group=primary 2 3 4 5 elasticsearch cluster Master-2 Master-1 node. SLB Node-[1-5] Master master No No Yes data No Yes No 0
  9. 9. Additional info • cluster.routing.allocation.* • index.routing.allocation.* • cluster reroute http://www.elasticsearch.org/guide/en/elasticsearc h/reference/current/index.html http://www.elasticsearch.org/videos/scalingmassive-elasticsearch-clusters/

×