分布式系統(tǒng)的高可用性與可擴(kuò)展性

image.png
ES的分布式特性

image.png
Master-eligible nodes 和 Master Node

image.png
Data node 與 Coordinating Node
當(dāng)集群無(wú)法保存數(shù)據(jù)時(shí),可以增加數(shù)據(jù)節(jié)點(diǎn),解決問(wèn)題

image.png
其他節(jié)點(diǎn)類型

image.png
節(jié)點(diǎn)配置

image.png
分片 (Primary Shard & Replica Shard)

image.png

image.png
分片的設(shè)定

image.png
查看分片的健康狀況

image.png

image.png
一個(gè)node對(duì)應(yīng)一個(gè)es instance
一個(gè)node可以有多個(gè)index
一個(gè)index可以有多個(gè)shard
一個(gè)shard是一個(gè)lucene index(這個(gè)index是lucene自己的概念、和es的index不是一回事)
在kibana的dev console里,寫一個(gè)api,mac下按下cmd?/ 會(huì)跳到相應(yīng)的api
get _cat/nodes?v
GET /_nodes/es7_01,es7_02
GET /_cat/nodes?v
GET /_cat/nodes?v&h=id,ip,port,v,m
GET _cluster/health
GET _cluster/health?level=shards
GET /_cluster/health/kibana_sample_data_ecommerce,kibana_sample_data_flights
GET /_cluster/health/kibana_sample_data_flights?level=shards
#### cluster state
The cluster state API allows access to metadata representing the state of the whole cluster. This includes information such as
GET /_cluster/state
#cluster get settings
GET /_cluster/settings
GET /_cluster/settings?include_defaults=true
GET _cat/shards
GET _cat/shards?h=index,shard,prirep,state,unassigned.reason
相關(guān)閱讀