centos7搭建kafka集群
环境:kafka集群依赖zookeeper
zookeeper集群部署:http://blog.运维网.com/haoyonghui/2113660
centos7 ip:192.168.41.47
centos7 ip:192.168.41.127
centos7 ip:192.168.41.86
下载kafka
三台机器执行
# tar xf kafka_2.11-1.1.0.tgz -C /usr/local/
# mv /usr/local/kafka_2.11-1.1.0 /usr/local/kafka
# vim /usr/local/kafka/config/server.propertieshttp://s1.运维网.com/images/20180508/1525765405830296.png
注:三台主机broker.id 分别为1,2,3
http://s1.运维网.com/images/20180508/1525765466529492.png
http://s1.运维网.com/images/20180508/1525765490869320.png
其它默认即可
启动kafka
#./kafka-server-start.sh -daemon ../config/server.properties #以后台方式启动,查看9092端口
#./kafka-server-stop.sh #关闭kafka命令
登录zookeeper查看即可
官方安装文档:http://kafka.apache.org/documentation/
页:
[1]