Flink安装配置---高可用

本文详细介绍了如何配置Flink高可用集群,包括JobManager和TaskManager的设置,以及ZooKeeper集群的配置。通过具体步骤和配置文件示例,帮助读者理解Flink HA模式下各组件的作用和配置要点。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

(1)vi masters
[root@hdp-1 conf]# vi masters
hdp-1:8081
hdp-2:8081
(2)vi slaves

[root@hdp-1 conf]# vi slaves 
hdp-2
hdp-3
hdp-4

(3)vi flink-conf.yaml

#==============================================================================
# Common
#==============================================================================

# The external address of the host on which the JobManager runs and can be
# reached by the TaskManagers and any clients which want to connect. This setting
# is only used in Standalone mode and may be overwritten on the JobManager side
# by specifying the --host <hostname> parameter of the bin/jobmanager.sh executable.
# In high availability mode, if you use the bin/start-cluster.sh script and setup
# the conf/masters file, this will be taken care of automatically. Yarn/Mesos
# automatically configure the host name based on the hostname of the node where the
# JobManager runs.
jobmanager.rpc.address: hdp-1

# The number of task slots that each TaskManager offers. Each slot runs one parallel pipeline.
taskmanager.numberOfTaskSlots: 2

(4) vi zoo.cfg
[root@hdp-2 conf]# vi zoo.cfg

# ZooKeeper quorum peers
server.1=hdp-1:2888:3888
server.1=hdp-2:2888:3888
server.1=hdp-3:2888:3888
server.1=hdp-4:2888:3888
"zoo.cfg" 39L, 1505C written

每台都要配置!

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值