Elasticsearch集群环境搭建
Es集群搭建核心思想
1.配置相同集群名称
2.配置不同的节点ID
3.修改X台服务器elasticsearch.yml配置
服务器环境->准备三台服务器集群
服务器集群配置:
## 修改elasticsearch.yml文件
[ elasticsearch]# vim elasticsearch.yml
# ---------------------------------- Cluster -----------------------------------
#
# Use a descriptive name for your cluster:
# 取消注释,修改节点集群名称,保证三台服务器节点集群名称相同
cluster.name: chenxi
# ------------------------------------ Node ------------------------------------
#
# Use a descriptive name for the node:
# 取消注释,每个节点名称不一样,其他两台为node-2, node-3
node.name: node-1
# ---------------------------------- Network -----------------------------------
#
# Set the bind address to a specific IP (IPv4 or IPv6):
# 取消注释,服务器IP地址
network.host: 192.168.0.1
# --------------------------------- Discovery ----------------------------------
#
# Pass an initial list of hosts to perform discovery when new node is started:
# The default list of hosts is ["127.0.0.1", "[::1]"]
# 取消注释,多个服务器集群IP
discovery.zen.ping.unicast.hosts: ["192.168.0.1","192.168.0.2","192.168.0.3"]
#
# Prevent the "split brain" by configuring the majority of nodes (total number of master-eligible nodes / 2 + 1):
# 取消注释,设置最小主节点为1
discovery.zen.minimum_master_nodes: 1
###关闭防火墙###
注意克隆data文件会导致数据不同步
启动错误信息:
某台集群服务器报错 failed to send join request to master 时
解决办法:
清除每台服务器data文件
集群验证地址:
如成功显示如下:
192.168.0.1 18 93 1 0.00 0.00 0.00 mdi * node-1
192.168.0.2 20 96 2 0.00 0.03 0.11 mdi - node-2
192.168.0.3 20 96 2 0.00 0.05 0.11 mdi - node-3
相关推荐
newbornzhao 2020-09-14
做对一件事很重要 2020-09-07
renjinlong 2020-09-03
明瞳 2020-08-19
李玉志 2020-08-19
mengyue 2020-08-07
molong0 2020-08-06
AFei00 2020-08-03
molong0 2020-08-03
wenwentana 2020-08-03
YYDU 2020-08-03
另外一部分,则需要先做聚类、分类处理,将聚合出的分类结果存入ES集群的聚类索引中。数据处理层的聚合结果存入ES中的指定索引,同时将每个聚合主题相关的数据存入每个document下面的某个field下。
sifeimeng 2020-08-03
心丨悦 2020-08-03
liangwenrong 2020-07-31
sifeimeng 2020-08-01
mengyue 2020-07-30
tigercn 2020-07-29
IceStreamLab 2020-07-29