资讯

精准传达 • 有效沟通

从品牌网站建设到网络营销策划,从策略到执行的一站式服务

spark-master高可用测试

spark-master 高可用测试:

创新互联建站主要从事做网站、成都做网站、网页设计、企业做网站、公司建网站等业务。立足成都服务嫩江,十余年网站建设经验,价格优惠、服务专业,欢迎来电咨询建站服务:028-86922220

集群介绍

[spark-m]
172.20.101.157 sparkname=master01 
172.20.101.164 sparkname=master02
172.20.101.165 sparkname=master03 

[spark-s]
172.20.101.160 sparkname=slave01 
172.20.101.166 sparkname=slave02
172.20.101.167 sparkname=slave03 

[zookeeper]
172.20.101.157 myid=1 
172.20.101.164 myid=3 
172.20.101.165 myid=2 

启动第1台master:

[root@kubm-03 ~]# tailf /var/log/spark/spark-root-org.apache.spark.deploy.master.Master-1-kubm-03.out 
.......
19/07/18 11:11:59 INFO ZooKeeperLeaderElectionAgent: We have gained leadership
19/07/18 11:11:59 INFO Master: I have been elected leader! New state: ALIVE

发现第1台未发现其它节点,状态选举为 leader

启动第2台master:

[root@kubm-02 ~]# sh /usr/local/spark-2.4.3-bin-hadoop2.7/sbin/start-master.sh 
.......
19/07/18 11:17:52 INFO ConnectionStateManager: State change: CONNECTED

状态选举为 CONNECTED

启动第2台master:

[root@kubm-01 ~]# sh /usr/local/spark-2.4.3-bin-hadoop2.7/sbin/start-master.sh 
.。。。。
19/07/18 11:15:09 INFO ConnectionStateManager: State change: CONNECTED

状态选举为 CONNECTED

关闭 leader 节点服务

[root@kubm-03 ~]# sh /usr/local/spark-2.4.3-bin-hadoop2.7/sbin/stop-master.sh 

略等待,kubm-01节点选举为新的 leader

[root@kubm-01 ~]# 
19/07/18 11:19:33 INFO ZooKeeperLeaderElectionAgent: We have gained leadership
19/07/18 11:19:33 INFO Master: I have been elected leader! New state: ALIVE

名称栏目:spark-master高可用测试
标题链接:http://cdkjz.cn/article/jgihoo.html
多年建站经验

多一份参考,总有益处

联系快上网,免费获得专属《策划方案》及报价

咨询相关问题或预约面谈,可以通过以下方式与我们联系

大客户专线   成都:13518219792   座机:028-86922220