首页 > 其他 > 详细

单机安装zookeeper和kafka

时间:2021-05-17 21:46:55      阅读:10      评论:0      收藏:0      [点我收藏+]

一、Zookeeper
1. 下载解压
tar -zxvf apache-zookeeper-3.6.3-bin.tar.gz
1
2. 配置(非必须)
cd conf/
cp zoo_sample.cfg zoo.cfg
vi zoo.cfg

可以根据自己的需要进行配置,一般默认即可

# The number of milliseconds of each tick
tickTime=2000
# The number of ticks that the initial
# synchronization phase can take
initLimit=10
# The number of ticks that can pass between
# sending a request and getting an acknowledgement
syncLimit=5
# the directory where the snapshot is stored.
# do not use /tmp for storage, /tmp here is just
# example sakes.
dataDir=/tmp/zookeeper
# the port at which the clients will connect
clientPort=2181

3. 启动zookeeper
启动命令:./bin/zkServer.sh

root@ACE:/usr/local/zookeeper/apache-zookeeper-3.6.3-bin# ./bin/zkServer.sh start
ZooKeeper JMX enabled by default
Using config: /usr/local/zookeeper/apache-zookeeper-3.6.3-bin/bin/../conf/zoo.cfg
Starting zookeeper ... STARTED

 

 

下载kafka  二进制文件

 

http://mirrors.tuna.tsinghua.edu.cn/apache/kafka/2.3.0/kafka_2.12-2.3.0.tgz
tar -xzvf kafka_2.12-2.3.0.tgz
mv kafka_2.12-2.3.0 kafka
bin/zookeeper-server-start.sh -daemon config/zookeeper.properties

 

 

参考地址: 单机zookeeper和kafka的安装和启动_郭建華的博客-CSDN博客

单机安装zookeeper和kafka

原文:https://www.cnblogs.com/yanzi2020/p/14778080.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!