1.下载kafka非源码安装包
2.修改configzookeeper.properties
# 修改成自己的目录 dataDir=G:kafkazookeeperdata
3.启动zookeeper
binwindowszookeeper-server-start.bat configzookeeper.properties
4.启动kafka
binwindowskafka-server-start.bat configserver.properties
5.测试
#创建Topic binwindowskafka-topics.bat --create --zookeeper localhost:2181 --replication-factor 1 --partitions 1 --topic kafka #显示数据 binwindowskafka-topics.bat --list --zookeeper localhost:2181