mkdir -p /export/servers/ mkdir -p /export/software / mkdir -p /export/data / mkdir -p /export/logs / |
tar -zxvf kafka_2.11-1.0.0.tgz -C /export/servers/ cd /export/servers/ rm -rf /export/servers/kafka rm -rf /export/logs/kafka/ rm -rf /export/data/kafka mv kafka_2.11-1.0.0 kafka |
# broker.id 标识了kafka集群中一个唯一broker。 broker.id=0 num.network.threads=3 num.io.threads=8 socket.send.buffer.bytes=102400 socket.receive.buffer.bytes=102400 socket.request.max.bytes=104857600 # 存放生产者生产的数据 数据一般以topic的方式存放 # 创建一个数据存放目录 /export/data/kafka --- mkdir -p /export/data/kafka log.dirs=/export/data/kafka num.partitions=1 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 # zk的信息 zookeeper.connect=zk01:2181,zk02:2181,zk03:2181 zookeeper.connection.timeout.ms=6000 group.initial.rebalance.delay.ms=0 |
rm -rf /export/servers/kafka rm -rf /export/logs/kafka/ rm -rf /export/data/kafka |
scp -r /export/servers/kafka/ node02:/export/servers/ scp -r /export/servers/kafka/ node03:/export/servers/ |
vi /export/servers/kafka/config/server.properties |
vi /export/servers/kafka/config/server.properties |
cd /export/servers/kafka/bin ./kafka-server-start.sh /export/servers/kafka/config/server.properties |
欢迎光临 黑马程序员技术交流社区 (http://bbs.itheima.com/) | 黑马程序员IT技术论坛 X3.2 |