Kafka集群部署
运行环境:
❤ 操作系统:CentOS7.6 x64
❤ kafka版本:kafka_2.13-3.3.1.tgz
❤ JDK环境:JDK11
(Kafka2.8版本才开始自带了Zookeeper,所以注意下载版本)
一、zookeeper.properties
dataDir=/tmp/zookeeper/data
clientPort=2181
tickTime=2000
initLimit=10
二、server.properties
broker.id=3
listeners=PLAINTEXT://10.8.198.88:9092
advertised.listeners=PLAINTEXT://10.8.198.88:9092
num.network.threads=3
num.io.threads=8
socket.send.buffer.bytes=102400
socket.receive.buffer.bytes=102400
socket.request.max.bytes=104857600
log.dirs=/tmp/kafka-logs
num.partitions=5
num.recovery.threads.per.data.dir=1
offsets.topic.replication.factor=1
transaction.state.log.replication.factor=1
transaction.state.log.min.isr=1
log.retention.hours=168
log.segment.bytes=1073741824
log.retention.check.interval.ms=300000
zookeeper.connect=10.8.198.66:2181,10.8.198.77:2181,10.8.198.88:2181
zookeeper.connection.timeout.ms=18000